Search Results

Search found 687 results on 28 pages for 'keith johnson'.

Page 19/28 | < Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >

  • PHP: How can I eliminate quotes around output from CSV file?

    - by brian johnson
    This code: <?php $curl=curl_init(); curl_setopt ($curl,CURLOPT_URL,"http://download.finance.yahoo.com/d/quotes.csv?s=XIN&f=l1c1p2rj1y&e=.csv"); curl_setopt ($curl,CURLOPT_HEADER,0); ob_start(); curl_exec ($curl); curl_close ($curl); $data=ob_get_clean(); $data = explode(",",$data); foreach ($data as $results) echo "<td>$results</td>"; ?> yields these results in my browser: 2.80 +0.02 "+0.72%" 1.85 204.2M 1.44 How can I have this PHP code above eliminate the quotations around the "+0.72%" so the end result is just: 0.72% ?

    Read the article

  • Learning OpenGL ES 1.x

    - by Kristopher Johnson
    What is the quickest way to come up to speed on OpenGL ES 1.x? Let's assume I know nothing about OpenGL (which is not entirely true, but it's been a while since I last used OpenGL). I am most interested in learning this for iPhone-related development, but I'm interested in learning how it works on other platforms as well. I've found the book OpenGL ES 2.0 Programming Guide, but I am concerned that it might not be the best approach because it focuses on 2.0 rather than 1.x. My understanding is that 2.0 is not backwards-compatible with 1.x, so I may miss out on some important concepts. Note: For answers about learning general OpenGL, see http://stackoverflow.com/questions/62540/learning-opengl Some resources I've found: http://khronos.org/opengles/1_X/ http://www.imgtec.com/powervr/insider/sdk/KhronosOpenGLES1xMBX.asp OpenGL Distilled by Paul Martz (a good refresher on OpenGL basics)

    Read the article

  • What are possible/good ways to prototype iPhone applications?

    - by Ted Johnson
    This is intentionally left broad. If you wanted to show users what iPhone/mobile applications could to for them. The more interactive the better, but it must be quick to build as you can't code up every idea. Let us assume real-time games are out of scope. Throw out ideas or state which approach would be best. Here are some of my ideas, what are yours? Hack a app that loads mostly web or image content, but has hyperlinks to get around in. This would mean static data. Build screens which look great but can only be navigated in a story board type fashion. Load the web version or equivalent on the iPhone and say: now image the buttons and navigation is better. A paper based prototype. Flash or video walk through running on the phone. String existing iPhone apps and web pages together with minimal glue just to convey the idea. Can anyone share prototyping methods for other mobile devices? Ex: The palm prototype was just a block of wood and note pad that was carried around.

    Read the article

  • How to delay hiding of a menu with Jquery Dropdown Menu?

    - by Keith Donegan
    I have a dropdown menu that works fine, but I would like it so, that if I hover off the menu, it doesn't immediately hide again. So basically I would like a one second delay. I have read about setTimeout, but not sure if it is what I need? $('#mainnav a').bind('mouseover', function() { $(this).parents('li').children('ul').show(); }); $('#mainnav a').bind('mouseout', function() { $(this).parents('li').children('ul').hide(); });

    Read the article

  • Tracking DB changes with Zend Framework?

    - by Chad Johnson
    I am trying to decide between the Zend Framework and Ruby On Rails for my web application. If I go with ZF, I need the following: A way to incrementally track changes to my database, as with RoR's migration feature (001_something.sql, 002_something_else.sql). A place to put SQL for the next release of my software. At work in our custom PHP solution, we just have release.sql, which gets run, archived, and blanked out upon release. ZF has Zend_Db_Schema_Manager, which does the same thing, but I'm not interested as its not official, complete, or maintained. Is there an official mechanism that ZF provides for doing something similar to what I described? EDIT I ended up going with Rails. Nothing compares.

    Read the article

  • Why use a Rails-like deployment mechanism over 'git pull' for releasing?

    - by Chad Johnson
    To release my centralized webapp, I COULD have a vhost pointed to some directory and then just do a 'git pull' when I want to release, updating the files. But Rails has a different deployment mechanism: it copies files to a subdirectory and then points a symlink ('current') to that new subdirectory. I understand that it probably more acceptable to do a Rails-like deployment because the release is built in some directory, and then the symlink is pointed to that directory, so this is much faster, and it's less likely that users would experience weird issues while a release is happening. Are there any other advantages to the Rails approach? Or, is a 'git pull' approach actually more widely accepted?

    Read the article

  • tool to auto-format R code

    - by Keith
    Is there any tool (editor, script, whatever...) available that can automatically reformat R code? It does not need to be customizable but it must be able to recognize statements separated by either semicolons or newlines since this code has both. If it can put all statements on a separate line, consistently indent code blocks and consistently place braces I will be very happy.

    Read the article

  • SubSonic isn't generating MySql foreign key tables

    - by keith
    I two tables within a MySql 5.1.34 database. When using SubSonic to generate the DAL, the foreign-key relationship doesn't get scripted, ie; I have no Parent.ChildCollection object. Looking inside the generated DAL Parent class shows the following; //no foreign key tables defined (0) I have tried SubSonic 2.1 and 2.2, and various MySql 5 versions. I must be doing something wrong procedurally - any help would be greatly appreciated. This has always just worked 'out-the-box' when using MS-SQL. TABLE `parent` ( `ParentId` INT(11) NOT NULL AUTO_INCREMENT, `SomeData` VARCHAR(25) DEFAULT NULL, PRIMARY KEY (`ParentId`) ) ENGINE=INNODB DEFAULT CHARSET=latin1; TABLE `child` ( `ChildId` INT(11) NOT NULL AUTO_INCREMENT, `ParentId` INT(11) NOT NULL, `SomeData` VARCHAR(25) DEFAULT NULL, PRIMARY KEY (`ChildId`), KEY `FK_child` (`ParentId`), CONSTRAINT `FK_child` FOREIGN KEY (`ParentId`) REFERENCES `parent` (`ParentId`) ) ENGINE=INNODB DEFAULT CHARSET=latin1;

    Read the article

  • Can you make an incrementing compiler constant?

    - by Keith Nicholas
    While sounding nonsensical..... I want a Contant where every time you use it it will increment by 1 int x; int y; x = INCREMENTING_CONSTNAT; y = INCREMENTING_CONSTNAT; where x == 1; and y == 2 Note I don't want y = INCREMENTING_CONSTNAT+1 type solutions. Basically I want to use it as a compile time unique ID ( generally it wouldn't be used in code like the example but inside another macro)

    Read the article

  • JQuery nth-child not working properly

    - by Keith Donegan
    Hi Guys, I am using JQuery's nth-child selector to alter the margin on every 3rd div with a class of photo_post_thumbnail, but it alters it every 2nd div? Can anyone spot what I am doing wrong? Site http://www.clients.eirestudio.net/hatstand/wordpress/photos/ HTML markup <div class="postbox photo_post_thumbnail"> blah blah </div> <div class="postbox photo_post_thumbnail"> blah blah </div> <div class="postbox photo_post_thumbnail"> blah blah </div> JQuery Code $('.photo_post_thumbnail:nth-child(3n)').css('margin-right', '0px');

    Read the article

  • C when to allocate and free memory - before function call, after function call...etc

    - by Keith P
    I am working with my first straight C project, and it has been a while since I worked on C++ for that matter. So the whole memory management is a bit fuzzy. I have a function that I created that will validate some input. In the simple sample below, it just ignores spaces: int validate_input(const char *input_line, char* out_value){ int ret_val = 0; /*false*/ int length = strlen(input_line); cout << "length = " << length << "\n"; out_value =(char*) malloc(sizeof(char) * length + 1); if (0 != length){ int number_found = 0; for (int x = 0; x < length; x++){ if (input_line[x] != ' '){ /*ignore space*/ /*get the character*/ out_value[number_found] = input_line[x]; number_found++; /*increment counter*/ } } out_value[number_found + 1] = '\0'; ret_val = 1; } return ret_val; } Instead of allocating memory inside the function for out_value, should I do it before I call the function and always expect the caller to allocate memory before passing into the function? As a rule of thumb, should any memory allocated inside of a function be always freed before the function returns?

    Read the article

  • <asp:Table> Vs html <table>

    - by keith
    What are the pros and cons between using the ASP.Net control compared to the old reliable table html implementation. I know that the asp:Table will end up on the returned page as a html table, and from looking into it so far people are saying its easier to work with the asp:Table in the server side code, but I'd love to hear what the stackoverflow community has to say about the matter.

    Read the article

  • JQuery - How to add a single html tag to some html?

    - by Keith Donegan
    Hey Guys, I want to insert just a single <span> before the text below (right before LINK): <li><a href="">LINK</a></li> So, the above becomes <li><a href=""><span>LINK</a></li> Here is my JQuery Code: $('#mainnav li a').prepend('<span>'); When I view the code in firebug after, I see , how do I just get the opening span tag and not the closing tag?

    Read the article

  • MS Word to Stylesheet

    - by Chris Johnson
    Is there an easy way to automatically convert a bunch of MS Word documents to xslt stylesheets that can be displayed in the browser? What I have is a large collection of forms in Word format that have to be displayed in the browser, or sent to the user, with known fields populated from a data source, edited by a user and, finally, printed (including the original headers and footers). The data entered by the user will not need to be saved. I'm not sure if converting the documents to stylesheets is even feasible. Maybe someone has a better idea of how to achieve this? Installing Office on the server is not an option in my case.

    Read the article

  • Chrome starts to load image then show broken link icon

    - by Clare A Keith Ward
    Chrome (21.0.1180.79 m) On several random pages it has started to load an image and then suddenly the image disappears and there's only the broken image icon. If I right click the icon and choose to open the image in another window then the image opens, so it seems to me that it isn't a problem with the page? Here's one of the pages that it does it on; http://welshjournals.llgc.org.uk/browse/viewpage/llgc-id:1048090/llgc-id:1048951/llgc-id:1048969/get650 I'm running Kaspersky Internet Security 2012 Any help would be appreciated. Thanks Clare

    Read the article

  • Variable collation with MySQL stored function?

    - by Chad Johnson
    I want to do something like this in a stored procedure: IF case_sensitive = FALSE THEN SET search_collation = "utf8_unicode_ci"; ELSE SET search_collation = "utf8_bin"; END IF; INSERT INTO TABLE1 (field1, field2) SELECT * FROM TABLE 2 WHERE some_field LIKE '%rarf%' collate search_collation; However, when I do this, I get ERROR 1273 (HY000): Unknown collation: 'search_collation' Also, if I do what's suggested at http://stackoverflow.com/questions/1680850/mysql-stored-procedures-use-a-variable-as-the-database-name-in-a-cursor-declara/2070021#2070021 I get Dynamic SQL is not allowed in stored function or trigger How can I use a dynamic collation?

    Read the article

  • Override app.config settings embedded into a MSI?

    - by Seth Petry-Johnson
    I have a .NET solution with an installer project that generates an MSI. One of the projects installed by the MSI contains an App.Config file. It appears that the values of that config file are embedded into the MSI at compile time. Is there a way to override them at runtime? For instance, the App.Config I'm working with sets the URL of a web service that the installer talks to. Is it possible to override this URL at runtime, so that I don't have to recompile the MSI if the URL changes?

    Read the article

  • rawurlencode() and urlencode() not working in CodeIgniter

    - by Keith Chason
    I am trying to encode a string into a safe url for generic purposes, and neither rawurlencode() nor urlencode() work when using CodeIgniter. I have used them and they work pefectly fine with straight PHP, but for whatever reason, it doesn't work. I haven't been able to find any others with this problem and thus no solution. Code: <a href="/search/degree/<?=rawurlencode($row->degree)?>" class="element_link"><?=$row->degree?></a>

    Read the article

  • How to save Application State using NSUserDefaults in iPhone?

    - by keith
    Hello Everyone, Following is what i am doing: - (void) applicationWillTerminate: (UIApplication*) application { NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; [defaults setObject:navigationController.viewControllers forKey:@"diabetesstate"]; } - (void) applicationDidFinishLaunching: (UIApplication*) application { NSMutableArray *state = [[NSUserDefaults standardUserDefaults] objectForKey:@"diabetesstate"]; if (state == nil) { //Will initialize a new controller and put it as root view controller } else { [navigationController setViewControllers:state animated:NO]; } }

    Read the article

  • How to be notified when a script's background job completes?

    - by Keith Bentrup
    My question is very similar to this one except that my background process was started from a script. I could be doing something wrong but when I try this simple example: #!/bin/bash set -mb # enable job control and notification sleep 5 & I never receive notification when the sleep background command finishes. However, if I execute the same directly in the terminal, $ set -mb $ sleep 5 & [1]+ Done sleep 5 I see the output that I expect. I'm using bash on cygwin. I'm guessing that it might have something to do with where the output is directed, but trying various output redirection, I'm not getting any closer?

    Read the article

  • jQuery sortable: Revert changes if update callback makes an AJAX call that fails?

    - by Seth Petry-Johnson
    I am using the jQuery sortable() feature to re-order a list of items. After an item is drug to a new location, I kick off an AJAX form post to the server to save the new order. How can I undo the sort (e.g. return the drug item to its original position in the list) if I receive an error message from the server? Basically, I only want the re-order to "stick" if the server confirms that the changes were saved.

    Read the article

< Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >