Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. trollacious

    I'd like help with code

    It looks like you have line of code split across 2 lines, which Javascript doesn't like. Put it all on one line or break the calculation into 2 separate operations. Lee
  2. trollacious

    JS function help

    Use an else instead of your second if statement in each function. As well in your removeRow function, you use if ( showing = 0 ) which should be if ( showing == 0 ) Lee
  3. trollacious

    script to stop right click seems to need alert() in it

    You can also just hit the Enter key while continuing to hold the right mouse button down. The alert window will disappear and the context menu will come up as usual. What makes this "trick" work is someone using the mouse for everything will click on the alert OK button which will cancel out...
  4. trollacious

    Apostrpohe and quote nightmare!

    Try apostrophes. Lee
  5. trollacious

    Percentage of 2 times

    How would you add 2 times together on paper? Once you describe that process, it's not difficult to write the code to do that in JS. Lee
  6. trollacious

    Percentage of 2 times

    Think about it. How would you add the times together on paper using a pencil? Write the code for that. Lee
  7. trollacious

    Percentage of 2 times

    Since both op1 and op2 are readonly, what's going to trigger the onchange event. Also, because of the format of your time values, you're going to have a hard time adding or multiplying them without converting to total seconds first. The hh:mm:ss format doesn't convert to a Number object...
  8. trollacious

    Problem with dates and variables

    T3 = T2 means you have 2 different variable names that refer to the same object. When you change T3, then T2 is changed as well. If you're familiar with pointers in C/C++, both variables point to the same object. Because you first document.write T2 before you change T3, it displays as you...
  9. trollacious

    Rotating banners

    The following has an error in it that will terminate the Javascript function: var thePicture=document.getElementById("header"; You need a closing parenthesis. If you actually have a closing parenthesis, then in the future you need to copy and paste your code so we see EXACTLY what you have...
  10. trollacious

    setting object1 = object2 causes error

    Are you trying to assign the value of one to be the value of the other? Lee
  11. trollacious

    Validator @ W3 not liking mailto: statement

    You need BOTH script tags, the one to load the external JS file and the one to call the function, the way you're trying to do it now. Or you can put the HideMail() function call in the external JS file and then just load it (your first example) where you want it to display. Lee
  12. trollacious

    Validator @ W3 not liking mailto: statement

    If you use the src attribute, you can't put a function call inside the JS tags. Gotta be something like the following in the body: <script type="text/javascript"> HideEmail(); </script> Lee
  13. trollacious

    reading input from user and displaying it back on the page

    Try using document.getElementById(id).value rather than frmOne.xxxxx.value. Lee
  14. trollacious

    Right write in of the command

    Where are you declaring res1? One way is to put it in a file that's included in both Form1 and Form2. You wouldn't use Form1->res1 then, just res1. If you want to use Form1->res1, make sure res1 is a public variable and not private. The same goes for res4. Lee
  15. trollacious

    Image Preloader?

    I have used a simpler preload function for years: var preimages = new Array(); function imgpreload(imgarray) { for (var ii = 0; ii < imgarray.length; ii++) { preimages[ii] = new Image(); preimages[ii].src = imgarray[ii]; } } imgpreload(picSrc); Lee
  16. trollacious

    Links not working in Firefox

    Show your code. Copy and paste it in here, don't type it over. If the page is online, you can also give us a URL for us to test to see what the problem is. Lee
  17. trollacious

    Time sensitive hyperlink. Is it possable ?

    Phil, you gave me an idea how to do this and still make it secure from MOST people. If you put the link in a cookie along with the expiration time, then you could read the cookie to get the link and put it in a variable, then write that to the page dynamically with either document.write when...
  18. trollacious

    Time sensitive hyperlink. Is it possable ?

    The link would still be visible in the source, though, so someone could access the file directly using that. Lee
  19. trollacious

    Time sensitive hyperlink. Is it possable ?

    Using server-side scripting (PHP, ASP, ASP.NET, Cold Fusion, JSP, etc.) to indicate the initial time on the page for Javascript to work with, you can make a link that will expire whenever you want. However, anyone with Javascript turned off wouldn't be limited to your time out period. Lee
  20. trollacious

    Works in IE, not Firefox - anything obvious here?

    Something like this: function fill_contact() { with (document.getElementById('frmContact')) { if (chbsame.checked == true) { vnds_scntct_fnm.value = vnds_cntct_fnm.value; vnds_scntct_lnm.value = vnds_cntct_lnm.value...

Part and Inventory Search

Back
Top