Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8234583
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T18:31:48+00:00 2026-06-07T18:31:48+00:00

I load some .js dynamically by creating a script tag and writing javascript to

  • 0

I load some .js dynamically by creating a script tag and writing javascript to the .innerHTML of it.

I get this error:

SCRIPT1004: Expected ';' 
develop, line 1487 character 24

This makes no sense…so I’m guessing it is reporting the line number correctly or wrong all together (I’m at least happy it made it this far with out failing out….1487 is near the end of my code ).

Firefox usually reports the correct line but it is always off by 1 line. I assumed IE9 would as well…

How can I troubleshoot. I already verified the code passes jshint.com which makes it even more strange that it is expecting a ;. Jshint would have caught this if it was real.

Flying blind on IE9 pretty much.

Here is the code: w/ 10 lines above and 10 line below. Line 1487 is commented as such.

    /**
     *Publik
     */

    var publik = {};
    publik.initMenu = function( )
    {
        top_element = document.getElementById( 'top_new' ); 
        bottom_element = document.getElementById( 'wrap_drop_down_new' );
        top_element.addEventListener( "mouseout", mouse_out, false ); 
        top_element.addEventListener( "mouseover", top_mouse_over, false ); // Line 1487
        bottom_element.addEventListener( "mouseout", mouse_out, false ); 
        bottom_element.addEventListener( "mouseover", bottom_mouse_over, false ); 
    };
    return publik;

}());
/*  Use this to create Event on completion of .js and remove cStart().

    var event_load_js = document.createEvent("HTMLEvents");
    event_load_js.initEvent( "blur", true, false );

Code containig top_mouse_over per request of Beat

/**
 *MMenu
 */

var MMenu = ( function () 
{
    /**
     *Private
     */

    var top_element,
        bottom_element,
        time_out_id = 0,
        TIME_DELAY = 1000;

    function showBottom()
    {
        top_element.style.border = '1px solid #cfcaca';
        top_element.style.borderBottom = '3px solid #cfcaca';
        bottom_element.style.visibility = 'visible';
    }
    function hideBottom()
    {
        top_element.style.border = '1px solid #faf7f7';
        bottom_element.style.visibility = 'hidden';
    }
    function top_mouse_over()
    {
        window.clearTimeout( time_out_id );
        showBottom();
    }
    function bottom_mouse_over()
    {
        window.clearTimeout( time_out_id );
    }
    function mouse_out()
    {
        time_out_id = window.setTimeout( hideBottom, TIME_DELAY );
    }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T18:31:51+00:00Added an answer on June 7, 2026 at 6:31 pm

    Copy your dynamically generated code from the browser and paste it into Notepad++ and search for “?” to see if you have any unicode characters. I’m pretty sure that the console isn’t telling the truth. I’ve ran into this before as well.

    See: https://stackoverflow.com/a/9246128/1220302

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

for some reason, whenever I dynamically load a swf on a $(document).ready() by writing
I need to load some js files dynamically and sequentially(i.e. second script loads after
I want to load some helper in a model. How to do this? Tried
I am creating some link buttons dynamically and try to access them in some
I'm creating a flash application which loads in some XML which is generated dynamically
First off, I am not dynamically creating any controls. This is the order I
In my application, I load some assemblies dynamically, depending on what was the user's
Im creating an application, wich will conect to several sql database and get some
I'm trying load some scripts dynamically with jQuery: var scripts = ['script1.js','script2.js','script3.js']; $.each(scripts ,
I am loading some images dynamically into a UITableView and creating some simple custom

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.