Search Results

Search found 1375 results on 55 pages for 'rob sanders'.

Page 45/55 | < Previous Page | 41 42 43 44 45 46 47 48 49 50 51 52  | Next Page >

  • In Safari, using jQuery a Form Input Text Field does not receive focus after alert is displayed. Why

    - by Rob
    I have an ASPX web form. I use jQuery to simply my Javascript. I use a Javascript validation script to validate each of the form fields' values. If an error occurs, I popup an alert with an error message. Then I transfer focus to the underlying element. Here are examples I have tried. Using jQuery: var Form_FieldDef = function(name) { this.name = name; this.SetFocus = function() { $('#' + this.name)[0].focus(); } this.Validate = function() { var isvalid = true; if ( $.trim($('#' + this.name).val()) == '') { alert("Your entry is empty"); this.SetFocus(); isvalid = false; } return isvalid; } } This works on IE7, IE8, Opera, Chrome, and Firefox. It does not work on Safari 4 on PC. I don't have a Mac. So I changed the SetFocus method to this. this.SetFocus = function() { var fld = document.getElementById(this.name); if (fld != null) fld.focus(); } This works on IE7, IE8, Opera, Chrome, and Firefox. It does not work on Safari 4 on PC. I stepped through the code with VS 2008 debugger, and I'm calling the focus method on the underlying element.

    Read the article

  • HTML5 video on Chrome

    - by Rob
    I'm using the following HTML5 to display video, but only the controls show up in Chrome. Works fine in Safari and Firefox: <video width="720" height="480" controls="controls" preload="preload"> <source src="<?php bloginfo('url'); ?>/wp-content/uploads/Reel.ogv" type="video/ogg; codecs=theora,vorbis" > <source src="<?php bloginfo('url'); ?>/wp-content/uploads/Reel.mp4" type="video/mp4"> Your browser doesn't support video. </video> Any ideas?

    Read the article

  • How to ask questions to an obstructionist?

    - by Rob Wells
    This is not related to my other recently posted question about "working with a star developer". In a similar vein, how do you work with someone who will only answer the specific question that you ask. I worked with someone who, when you asked a question on a specific aspect of the system, would give you the answer just related to the specific bit you'd asked about. For example, when processing radar messages I'd ask about an aspect of message number RJ546 and he would answer just about that specific part of RJ546. He wouldn't mention anything about the other freaky parts of the message, or mention any related aspects of the other messages. Then you'd go off and work on the processing and all of a sudden all this other freakiness would pop up. What's a good technique when working with this type of person? BTW I later found out that the person who I'd come in to replace had quit because he got sick and tired of having these surprises pop up due to the lack of information provided by this person. Edit: I forgot to add that the person was deliberately obstructionist and believed that job security came from hoarded knowledge not being disseminated.

    Read the article

  • How can I pull multiple rows from a MySQL table and use all of them automatically for the same thing

    - by Rob
    Basically, I have multiple URL's stored in a MySQL table. I want to pull those URLs from the table and have cURL connect to all of them. Currently I've been storing the URL's in the local script, but I've added a new page that I can add and remove them from the database, and I'd like the page to reflect it appropriately. Here is what I currently have: $sites[0]['url'] = "http://example0.com "; $sites[1]['url'] = "http://example1.com"; $sites[2]['url'] = "http://example2.com"; $sites[3]['url'] = "http://example3.com"; foreach($sites as $s) { // Now for some cURL to run it. $ch = curl_init($s['url']); //load the urls and send GET data curl_setopt($ch, CURLOPT_TIMEOUT, 2); //No need to wait for it to load. Execute it and go. curl_exec($ch); //Execute curl_close($ch); //Close it off } Now I assume it can't be too amazingly difficult to do, I just don't know how. So if you could point me in the right direction, I'd be grateful. But if you supply me with some code, please comment it appropriately so that I can understand what each line is doing.

    Read the article

  • php memory how much is too much

    - by Rob
    I'm currently re-writing my site using my own framework (it's very simple and does exactly what I need, i've no need for something like Zend or Cake PHP). I've done alot of work in making sure everything is cached properly, caching pages in files so avoid sql queries and generally limiting the number of sql queries. Overall it looks like it's very speedy. The average time taken for the front page (taken over 100 times) is 0.046152 microseconds. But one thing i'm not sure about is whether i've done enough to reduce php memory usage. The only time i've ever encountered problems with it is when uploading large files. Using memory_get_peak_usage(TRUE), which I THINK returns the highest amount of memory used whilst the script has been running, the average (taken over 100 times) is 1572864 bytes. Is that good? I realise you don't know what it is i'm doing (it's rather simple, get the 10 latest articles, the comment count for each, get the user controls, popular tags in the sidebar etc). But would you be at all worried with a script using that sort of memory getting hit 50,000 times a day? Or once every second at peak times? I realise that this is a very open ended question. Hopefully you can understand that it's a bit of a stab in the dark and i'm really just looking for some re-assurance that it's not going to die horribly come re-launch day.

    Read the article

  • How can I gzinflate and save the inflated data without running it? (Found what I think is a trojan o

    - by Rob
    Well, not my server. My friend found it and sent it to me, trying to make sense of it. What it appears to be is a PHP IRC bot, but I have no idea how to decode it and make any sense of it. Here is the code: <?eval(gzinflate(base64_decode('some base 64 code here')))?> So I decoded the base64, and it output a ton of strange characters, I'm guessing either encrypted or a different file type, like when you change a .jpg to a .txt and open it. But I have no idea how to decode this and determine its source. Any help?

    Read the article

  • How would I automate my array to be used with cURL?

    - by Rob
    I have an array containing the contents of a MySQL table. I need to put each of these contents into curl_multi_handles so that I can execute them all simultaneously Here is the code for the array, in case it helps: $SQL = mysql_query("SELECT url FROM urls") or die(mysql_error()); while($resultSet = mysql_fetch_array($SQL)){ $urls[]=$resultSet } So I need to put be able to send data to each url at the same time. I don't need to get any data back, and in fact I'll be having them time out after two seconds. It only needs to send the data and then close. My code prior to this, was executing them one at a time. here is that code: $SQL = mysql_query("SELECT url FROM shells") or die(mysql_error()); while($resultSet = mysql_fetch_array($SQL)){ $ch = curl_init($resultSet['url'] . $fullcurl); //load the urls and send GET data curl_setopt($ch, CURLOPT_TIMEOUT, 2); //Only load it for two seconds (Long enough to send the data) curl_exec($ch); curl_close($ch); So my question is: How can I load the contents of the array into curl_multi_handle, execute it, and then remove each handle and close the curl_multi_handle?

    Read the article

  • How can I split a list with multiple delimiters?

    - by Rob
    Basically, I want to enter text into a text area, and then use them. For example variable1:variable2@variable3 variable1:variable2@variable3 variable1:variable2@variable3 I know I could use explode to make each line into an array, and then use a foreach loop to use each line separately, but how would I separate the three variables to use?

    Read the article

  • Passing a variable that can be updated

    - by Rob Bonner
    This seems like a simple thing, but can't get it to work. I pass a variable into a UIViewController thourgh a standard property: [aViewController setProposedDate:proposedWorkLog.entryDate]; which is retained by the controller, and possible changed. I have verified that in the controller, the data is modified. But, after it is popped off the stack and I look in the calling view, the data has not been updated. Is there a way to pass this variable and have it retain the new value, or a way to pass back a response from a closing view controller? Thanks!

    Read the article

  • Using PHP to determine if a localfile has been replaced?

    - by Rob
    I have a MySQL database with some URLs in it. One URL per row. Each URL has my script on it. What I am wanting to do, is check if the file is still there via a PHP script. Not check if it 404'd, but rather check if it has been modified or replaced. Is this possible? If so, how would it be accomplished?

    Read the article

  • Specified argument was out of the range of valid values. Parameter name: utcDate

    - by Rob
    Our logs show hundreds of these errors after our deployment if users are on the site. Anyone know what this means and how to fix it? Notes: We are using msdeploy, IIS 6 I recently noticed that our web server's time is about 10 minutes behind the real time, I think that may have something to do with it. If I log into our site, seems like any file that depends on a WebResource or ScriptResource type file doesn't look right. Seems to fix itself after an IIS reset

    Read the article

  • What to do with someone who can only use "the one true language"?

    - by Rob Wells
    G'day, How do you work with someone when they haven't been able to see that there is a range of other languages out there beyond "The One True Path"? I mean someone who hasn't grown up to realise that the modern software professional has a range of tools in his toolbox. Someone who has a well-equipped toolbox and then selects the best tool for the job at hand. The person who's knee jerk reaction is, for example, "We must do this is C++!" "Everything must be done in C++!" What's the best approach for these people? How do you open them up to the fact that "not everything is a nail." cheers,

    Read the article

  • Shell Prompt Line Wrapping Issue

    - by Rob
    I've done something to break my Bash Shell Prompt in OS X (10.5.7) Terminal. This is the PS1 that I had configured: PS1='\[\e[1;32m\]\h\[\e[0m\]:\[\e[1;34m\]\w\[\e[0m\]\$ ' As far as I can tell I have the color commands escaping correctly. However when I scroll up and down in my command history I often get line wrapping issues if the historic commands wrap onto multiple lines. I simplified my prompts to the following: PS1='\[\e[1m\]\h:\w\$ \[\e[0m\]' PS2='> ' And I still see something like: localhost:~/Library/Application Support/Firefox/Profiles/knpmxpup.Defau lt/extensions/{1A2D0EC4-75F5-4c91-89C4-3656F6E44B68}$ expocd \{1A2D0EC4-7 5F5-4c91-89C4-3656F6E export PS1="\[ \e[1;32m\]\h\[\e[0m\]: cd Library/Appl ication\ Support/ I've also tried \033 instead of \e. I just included PS2 up there for information, I haven't changed that from the install default. If I completely remove the color codes then everything works fine, any ideas?

    Read the article

  • Database design for business numbers

    - by Rob Morris
    I'm in need of some help, I need to store the information below into a database, what would the relational database structure be for this: Then I need to create a dropdown for the insurance company followed by another dropdown depending on what the first dropdown selected value was, then once both selects have been chosen display the relevant telephone number. I guess i need to query the database, then display the dropdowns using javascript(jquery) or Ajax?

    Read the article

  • Strange Puzzle - Invalid memory access of location

    - by Rob Graeber
    The error message I'm getting consistently is: Invalid memory access of location 0x8 rip=0x10cf4ab28 What I'm doing is making a basic stock backtesting system, that is iterating huge arrays of stocks/historical data across various algorithms, using java + eclipse on the latest Mac Os X. I tracked down the code that seems to be causing it. A method that is used to get the massive arrays of data and is called thousands of times. Nothing is retained so I don't think there is a memory leak. However there seems to be a set limit of around 7000 times I can iterate over it before I get the memory error. The weird thing is that it works perfectly in debug mode. Does anyone know what debug mode does differently in Eclipse? Giving the jvm more memory doesn't help, and it appears to work fine using -xint. And again it works perfectly in debug mode. public static List<Stock> getStockArray(ExchangeType e){ List<Stock> stockArray = new ArrayList<Stock>(); if(e == ExchangeType.ALL){ stockArray.addAll(getStockArray(ExchangeType.NYSE)); stockArray.addAll(getStockArray(ExchangeType.NASDAQ)); }else if(e == ExchangeType.ETF){ stockArray.addAll(etfStockArray); }else if(e == ExchangeType.NYSE){ stockArray.addAll(nyseStockArray); }else if(e == ExchangeType.NASDAQ){ stockArray.addAll(nasdaqStockArray); } return stockArray; } A simple loop like this, iterated over 1000s of times, will cause the memory error. But not in debug mode. for (Stock stock : StockDatabase.getStockArray(ExchangeType.ETF)) { System.out.println(stock.symbol); }

    Read the article

  • Autopruning after a specified amount of row are created?

    - by Rob
    Basic question, sorry. Basically, I have a script that creates a MySQL entry each time someone visits the page. A logging script. However, I want to make it autoprune after, say, 100 visits. For example in pseudo code: if amount of rows > 100 { delete rows 1+ until amount of rows == 100 } So in a nutshell, each time a new row is added after 100, it needs to automatically remove the row with the smallest id (My primary key).

    Read the article

  • Basic iphone timer example

    - by Rob
    Okay, I have searched online and even looked in a couple of books for the answer because I can't understand the apple documentation for the NSTimer. I am trying to implement 2 timers on the same view that each have 3 buttons (START - STOP - RESET). The first timer counts down from 2 minutes and then beeps. The second timer counts up from 00:00 indefinitely. I am assuming that all of the code will be written in the methods behind the 3 different buttons but I am completely lost trying to read the apple documentation. Any help would be greatly appreciated.

    Read the article

  • Which of the two exceptions was called?

    - by Rob
    If I have a routine that can throw an ArgumentException in two places, something like... if (Var1 == null) { throw new ArgumentException ("Var1 is null, this cannot be!"); } if (Val2 == null) { throw new ArgumentException ("Var2 is null, this cannot be either!"); } What’s the best way of determining in my calling procedure which of the two exceptions was thrown? Or Am I doing this in the wrong fashion?

    Read the article

  • Using PHP to grab the absolute URL of the script?

    - by Rob
    Basically, I want my script to output its absolute URL, but I don't want to statically program it into the script. For example, if my current URL is http://example.com/script.php I want to be able to store it as a variable, or echo it. i.e. $url = http://example.com/script.php; But if I move the script to a different server/domain, I want it to automatically adjust to that, i.e. $url = http://example2.com/newscript.php; But I have no idea how to go about doing this. Any ideas?

    Read the article

  • date comparison inside a list returned

    - by rob
    I have a ArrayList returned from a service which contains date-timestamp as String values (with values: 2010-05-06T23:38:18,2010-05-06T23:32:52,2010-04-28T18:23:06,2010-04-27T20:34:02,2010-04-27T20:37:02) to be more specific, This is part of a parent ArrayList ObjectHistory. This list contains the datestamp and serial number. I need to pick the correct serial number. Objecthistory is the List object and I need to get the latest timestamp within this ObjectHistory. I need to pick the latest timestamp from this Arraylist in Java 6. How should I be doing this? Should I do convert these values into calendar-time? I am in panic mode as this has to be done directly in production.

    Read the article

  • jQuery Code Only Fires On Hard Refresh?

    - by Rob Vanders
    The XFBML version of the Facebook Registration plugin only loads HTTPS. I need it to load HTTP so my form does not call a security error mismatch between domains. I wrote this code to get the SRC and rewrite it with out HTTPS It works fine on the first load, however on Chrome and Safari it only loads the first time and on HARD refreshes. It does not load on standard reloads or by pressing "enter" on the address bar. Here is the code $(window).load(function () { // Replace HTTPS with HTTP when frame has loaded $(".subscribe iframe").each(function(){ var source = $(this).attr("src"); //alert(source); var sourceNew = source.replace("https", "http"); // change https to http alert(sourceNew); $(this).attr("src", sourceNew); }); }); I have .HTACCESS set to disable server cache <Files *> Header set Cache-Control: "private, pre-check=0, post-check=0, max-age=0" Header set Expires: 0 Header set Pragma: no-cache </Files> What is causing this to not fire reliably? Thanks

    Read the article

< Previous Page | 41 42 43 44 45 46 47 48 49 50 51 52  | Next Page >