Results 1 to 5 of 5

Thread: "AnyLink JS Drop Down Menu v2.2" Error

  1. #1
    Join Date
    May 2010
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default "AnyLink JS Drop Down Menu v2.2" Error

    Hi everyone,

    I am using "AnyLink JS Drop Down Menu v2.2" (http://www.dynamicdrive.com/dynamici...pmenuindex.htm) to create some drop down menus on my website. The scripts work perfectly on Firefox and Chrome BUT it doesn't work on IE8. I always get this error when I run it on IE 8
    Code:
    Webpage error details
    
    User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0)
    Timestamp: Tue, 25 May 2010 02:10:51 UTC
    
    Message: 'items[...].1' is null or not an object
    Line: 168
    Char: 3
    Code: 0
    URI: file:///C:/Users/MINH/Desktop/VSA/VSA/scripts/anylinkmenu.js
    Which is this line "frag+='<li><a href="' + menuobj.items[i][1] + '" target="' + menuobj.linktarget + '">' + menuobj.items[i][0] + '</a></li>\n'"


    Please help!!!! How can I fix this error? I am new to javascript.

    Thank your very much.

    Site link: http://vsa.site90.com/
    Last edited by ddadmin; 05-25-2010 at 06:00 PM.

  2. #2
    Join Date
    May 2010
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Taken from http://stackoverflow.com/questions/6...-not-an-object
    The commenter on that post stated that autopostback = "false" instead of true(or default value?)fixed his error

  3. #3
    Join Date
    May 2010
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by Erik_M View Post
    Taken from http://stackoverflow.com/questions/6...-not-an-object
    The commenter on that post stated that autopostback = "false" instead of true(or default value?)fixed his error
    Thank you for your response but it still doesnt work for me.

    I add autopostback = "false" in that function but it still doesnt work.

  4. #4
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Inside menucontents.js, there should be NO comma following the last array element of each menu contents. In other words,the code in red below should be removed:

    Code:
    anylinkmenuConnect.items=[
    	["About Us", "aboutus.php"],
    	["Our Sponsors", "sponsors.php"],
    ]
    
    var anylinkmenuConnectSub={divclass:'anylinkmenu', inlinestyle:'', linktarget:''} //First menu variable. Make sure "anylinkmenu..." is a unique name!
    anylinkmenuConnectSub.items=[
    	["About Us", "../../../aboutus.php"],
    	["Our Sponsors", "../../../sponsors.php"],
    ]
    
    var anylinkmenuOfficersSub={divclass:'anylinkmenucols', inlinestyle:'', linktarget:'secwin'} //Third menu variable. Same precaution.
    anylinkmenuOfficersSub.cols={divclass:'column', inlinestyle:''} //menu.cols if defined creates columns of menu links segmented by keyword "efc"
    anylinkmenuOfficersSub.items=[
    	["Ricky Lin", "../../../officers/rickylin.php"],
    	["Mike Huynh", "../../../officers/mikehuynh.php"],
    	["Lisa Huynh", "../../../officers/lisahuynh.php"],
    	["Hien Nguyen", "../../../officers/hiennguyen.php"],
    	["Tin Nguyen", "../../../officers/tinnguyen.php", "efc"],
    	
    	
    	["Truy Tran", "../../../officers/truytran.php"],
    	["Jade Dewente", "../../../officers/jadedewente.php"],
    	["Ly-Van Nguyen", "../../../officers/lyvannguyen.php"],
    	["Vinh Phan", "../../../officers/vinhphan.php"],
    	["Tim Chung", "../../../officers/timchung.php",  "efc"],
    	
    	["Jeannie Tran", "../../../officers/jeannnietran.php"],
    	["Sophia Manguerra", "../../../officers/sophiamanguerra.php"],
    	["Cece Pham", "../../../officers/cecepham.php"],
    	["Kim Nguyen", "../../../officers/kimnguyen.php", ],
    	["Minh Bui", "../../../officers/minhbui.php"],
    
    ]
    
    
    var anylinkmenuOfficers={divclass:'anylinkmenucols', inlinestyle:'', linktarget:'secwin'} //Third menu variable. Same precaution.
    anylinkmenuOfficers.cols={divclass:'column', inlinestyle:''} //menu.cols if defined creates columns of menu links segmented by keyword "efc"
    anylinkmenuOfficers.items=[
    	["Ricky Lin", "officers/rickylin.php"],
    	["Mike Huynh", "officers/mikehuynh.php"],
    	["Lisa Huynh", "officers/lisahuynh.php"],
    	["Hien Nguyen", "officers/hiennguyen.php"],
    	["Tin Nguyen", "officers/tinnguyen.php", "efc"],
    	
    	
    	["Truy Tran", "officers/truytran.php"],
    	["Jade Dewente", "officers/jadedewente.php"],
    	["Ly-Van Nguyen", "officers/lyvannguyen.php"],
    	["Vinh Phan", "officers/vinhphan.php"],
    	["Tim Chung", "officers/timchung.php",  "efc"],
    	
    	["Jeannie Tran", "officers/jeannnietran.php"],
    	["Sophia Manguerra", "officers/sophiamanguerra.php"],
    	["Cece Pham", "officers/cecepham.php"],
    	["Kim Nguyen", "officers/kimnguyen.php", ],
    	["Minh Bui", "officers/minhbui.php"],
    
    ]
    IE is picky about such things.
    DD Admin

  5. #5
    Join Date
    May 2010
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    It works. Thank you admin.
    Sorry about hijacking the same threads.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •