Jump to content

jesh

Members
  • Posts

    2,293
  • Joined

  • Last visited

Everything posted by jesh

  1. You might have to encapsulate the data with quotation marks and then have your parser ignore commas that exist within quotes.For example:
  2. jesh

    ExampleJFrame.java

    I gave up on Java 6 years ago. Is it really as popular now as you are saying it is? I don't see too many sites with .jsp or .jhtml file extensions these days. And Flash seems to be much more widely used than Java Applets.
  3. Hah, that's exactly what I thought when I read the Russell quote. You seem very certain of yourself NotJustBrowsing.
  4. I only thought it'd be better because you'd still be able to see what the alerts where supposed to be alerting. If you are OK with completely ignoring the messages until you are logged in, then function alert() {} would probably be the best way.
  5. ROFL, check this:http://www.webmasterworld.com/forum91/1274.htm I just tested in Firefox and it works too...EDIT: This may be even better:function alert(string){ document.getElementById("display").innerHMTL += string + "<br />";}
  6. Great link. Within the first couple of sections I learned this: Which means this:var decimal = parseInt("FF8C00", 16) would have come in real handy for me when I was writing some color functions...
  7. Not in this case. I just viewed your source and saw that your code referenced a javascript. I viewed that script (by typing in the address in my address bar) and saw the problem.I suppose I could have just clicked on the "Script" tab in Firebug, but that's still a new Firefox extension for me and I'm still stuck with old habits.
  8. Yeah, they are search patterns. var string = " this is a test";string = string.replace(/^\\s+/g, ''); Does the same thing as: var string = " this is a test";while(string.substring(0,1) == " "){ string = string.substr(1);} As for other things you can do with javascript. Take a look at bit shifting (the << and >> operators). I don't fully understand it but I've seen some cool things done with it.Also, a fun one I've learned recently is that you can pass a reference to a function as a parameter to another function and then call that function on the inside: function a(string){ alert(string);}function b(string, func){ func(string);}b("What's up?!", a);
  9. It's because of cross server scripting. The page is being displayed at http://workbench.awardspace.com, and, hence, the javascript is being executed from there. However, the URL for your AJAX request is going to http://localhost/D6S/signup/signup.php?q=0". AJAX doesn't allow that.Try sending the AJAX request to "signup.php?q=0" instead.
  10. Although I found that they had a very steep learning curve, Regular Expressions aren't really all that difficult once you understand them. And they are ridiculously powerful.
  11. Oh, close the alert window? No, I don't believe that there is.
  12. Hmm...execution of the javascript pauses on alert. Could you do something like this? ...alert("An error has occurred, this window will close...");window.close(); Or, if you are trying to close a child window whose reference is held in a variable called "wnd", it'd be something like this: ...alert("An error has occurred, the child window will close...");wnd.close();
  13. The only thing in your code that I see right away is that your URL would be missing a ? after the filename.You might first try initially setting the url to "signup.php?" instead of "signup.php".
  14. Can you set the value of the vb variable to a hidden input inside a form?HTML: <input type="hidden" id="username" /> VB: document.getElementById("username").value = objNetwork.UserName Then, when you submit the form to the PHP page, it can see what the value of "username" is.
  15. jesh

    uploading file

    If "file" (or "files") is a directory, you can't save a file with that path. What you can do is save a file in that directory.You are still running: postedFile.SaveAs(savePath) Rather than postedFile.SaveAs(savePath & "\" & filename)
  16. Also, I meant to say "check out UTC(): http://www.w3schools.com/jsref/jsref_utc.asp" var date = UTC(); // date is in UTC (who cares about timezone!)
  17. Check out getUTCDate():http://www.w3schools.com/jsref/jsref_getUTCDate.asp
  18. jesh

    uploading file

    I seriously don't know how to do this in VB, but in C# you'd want to make sure you are trying to save the file to something like C:\Inetpub\wwwroot\tuition\files\MYFILE.EXT rather than C:\Inetpub\wwwroot\tuition\files. I think Windows is having a cow that you are trying to save a file as a directory.C#: string savePath = "C:\\Inetput\\wwwroot\\tuition\\files\\";...postedFile.SaveAs(savePath + filename);
  19. Did you see pulpfiction's posting in the HTML forum regarding the toFixed method?http://w3schools.invisionzone.com/index.ph...ost&p=63339See also:http://www.pageresource.com/jscript/j_a_03.htm
  20. Are you able to use Table variables in SQL Server 2000 like you can in SQL Server 2005? If so, might it be faster to run multiple INSERTs into that table variable and then do the joins on it rather than the multiple sets of joins? DECLARE @CIDs TABLE( cid int)
  21. The office is cold today, I'm bound to fat finger a few keystrokes myself!
  22. jesh

    possibility?

    I see you are using AJAX. If you want to simply have the script wait for a set amount of time before it runs, then what vijay wrote is exactly right. If, however, you want to wait for the response to come back from the AJAX request before you execute code, you'll want to use your ajaxResponse function as an event handler like this: xmlHttpObj.onreadystatechange = ajaxResponse;xmlHttpObj.open("GET", url, true);xmlHttpObj.send("");function ajaxResponse(){ if(xmlHttpObj.readyState == 4) { if(xmlHttpObj.status == 200) { var updtDiv = document.getElementById("updateDiv"); updtDiv.innerHTML = xmlHttpObj.responseText; } }}
×
×
  • Create New...