Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Mar 2012
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Chrome not loading javascript called from a frame page

    Here is the structure I am working with as this html/script was created by the chmProcessor to produce WebHelp files...

    index.htm contains:
    Code:
    <iframe id="mainFrame" name="mainFrame" class="full" src=
    "frameset.html">
    frameset.html contains:
    Code:
    <frameset cols="20%,80%">
    <frame id="treeFrame" src="tree.html" name="treeFrame" />
    <frame id="frameCont" src="2_Welcome.htm" name="Welcome" />
    </frameset>
    tree.html is the navigational panel and contains:
    Code:
    <script type="text/javascript" src="tree.js">
    </script>
    I have placed alert() calls in tree.js. When I load index.htm in Chrome, apparently tree.js is not being loaded because I do not see any alert box and the functionality within tree.js does not work.

    Note: The functionality does work in IE and Firefox

    If I open tree.html directly in Chrome, the tree.js functionality does get called.

    I do not know how to solve this problem or why Chrome is not loading the pages and script correctly. Thanks for your help!

  • #2
    New to the CF scene
    Join Date
    Mar 2012
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Well I believe I found the answer. Google has some security "feature" to protect you from yourself when it comes to dealing with local files. If I open Chrome with this command:
    chrome.exe --allow-file-access-from-files
    it works fine.

  • #3
    Senior Coder
    Join Date
    Dec 2010
    Posts
    2,396
    Thanks
    12
    Thanked 569 Times in 562 Posts
    Yes, I recently stumbled upon the same aspect when trying to use the new FileReader object from a local file.


  •  

    Posting Permissions

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