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 8527455
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T08:33:43+00:00 2026-06-11T08:33:43+00:00

I was testing our site, in IE8 and got the dreaded Unexpected call to

  • 0

I was testing our site, in IE8 and got the dreaded Unexpected call to method or property access. error.

After lots of debugging (IE8’s devtools suck), I found the offending line.

$('<script>').html(JSData).appendTo('head')

The problem is $('<script>').html(JSData). I tried running just that in the console, and I still got the error.

Why can’t IE8 set the .html on a newly created script tag?

P.S. This fails too:

$(document.createElement('script')).html(JSData)

UPDATE: I tried to create the script tag without jQuery:

var scriptTag = document.createElement('script');
scriptTag.type = 'text/javascript';
scriptTag.innerHTML = JSData;

On the scriptTag.innerHTML = JSData; line, IE8 gives Unknown runtime error. Thanks IE8.

  • 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-11T08:33:45+00:00Added an answer on June 11, 2026 at 8:33 am

    Your javascript only method needs to add the script element to the document.

    IE<9 does not recognize innerHTML or childNodes on script tags, but all browsers support the text property.

    var scriptTag = document.createElement('script');
    scriptTag.text= JSData;
    document.body.appendChild(scriptTag);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Our site contains href links to various subdomains: foo.mysite.com, bar.mysite.com. For testing purposes, I'd
Magento checkout broken in IE9 and IE8 for that matter When testing our checkout
I recently went live with our new home page, after heavily testing it in
I'm doing some testing against the creation of canonical links on our site, and
We've began testing our site in different browser and all of them work fine,
I'm testing a conversion of our site's database from Sql Server to MySQL on
We were testing our WPF application on Windows XP in the VMware Player (with
I want to begin unit testing our application, because I believe that this is
I am using Windows 2008 r2 64 bit system. While testing our script ,we
okay on our testing server the language works fine whetter your click it twice

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.