Web site script Error

Discussion in 'Software' started by Jodi, Sep 1, 2004.

  1. Jodi

    Jodi Private First Class

    I am getting an "Error on page" when I view on of my web sites, this line...<body onmousemove="closesubnav(event);"> it says "object expected". The site is worcesterpt.com ok who wants to tackle this one, Kodo, your the jack of all trades, I havent stumped you yet.
     
  2. goldfish

    goldfish Lt. Sushi.DC

    you need to pass an object to that function, I think. So closesubnav(this); generally object expected means you've escaped a string or you've tried to use somthing that doesnt exist (AFAIK event isn't even an object)
     
  3. Kodo

    Kodo SNATCHSQUATCH

    your javascript function:

    function closesubnav(event){
    if ((event.clientY <48)||(event.clientY > 107)){
    for (var i=1; i<= numofitems; i++){
    var shutdiv =eval('menuitem'+i+'.thediv');
    shutdiv.style.visibility='hidden';



    change numofitems to numberofmenuitems

    that's my best guess as I'm no javascript expert by any means.
     
  4. Jodi

    Jodi Private First Class

    Yikes, I tried both of those suggestions, and now along with the previous error still being there, I am receiving a new error when I save changes within Dreamweaver that says: "there is an error at line 9 column99 on "bike.htm" instancebegin tag inside editable region" But when I view the site, there is no script error on that particualr page, only the others, and the others are attached to the template, not bike.htm
    ~sincerely, confused!
     

MajorGeeks.Com Menu

Downloads All In One Tweaks \ Android \ Anti-Malware \ Anti-Virus \ Appearance \ Backup \ Browsers \ CD\DVD\Blu-Ray \ Covert Ops \ Drive Utilities \ Drivers \ Graphics \ Internet Tools \ Multimedia \ Networking \ Office Tools \ PC Games \ System Tools \ Mac/Apple/Ipad Downloads

Other News: Top Downloads \ News (Tech) \ Off Base (Other Websites News) \ Way Off Base (Offbeat Stories and Pics)

Social: Facebook \ YouTube \ Twitter \ Tumblr \ Pintrest \ RSS Feeds