A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Problem opening html files in Firefox

  1. #1
    Junior Member
    Join Date
    Feb 2007
    Posts
    4

    Problem opening html files in Firefox

    Hi, we are trying to open some html files from our flash projector (basically like an offline website). We open the html file using this code:

    just put, on a frame, it has:


    on (release) {
    getURL("website/portfolio.htm", "_blank");
    }


    website being the folder on the cd with the files in.
    If you already have firefox open, it opens the file fine. Or in IE if you have it open or not it will open it okay. But if you dont have firefox open it will just open firefox empty, without the file in.

    With a website URL it works fine:

    on (release) {
    getURL("www.website-name.com", "_blank");
    }

    Thanks for your help.

  2. #2
    Lifetime Friend of Site Staff Northcode's Avatar
    Join Date
    Dec 2000
    Location
    Whitehorse YT
    Posts
    3,764
    Have you tried adding file:// to the reference and/or using the entire path? If you know where the files are on the CD you can use this trick (below) to get the drive letter of the CD and from that you can construct the full path.

    drv = _url.substr(8,1);
    getURL("file://" + drv + ":\\website\\portfolio.html");

    That's assuming that the "website" folder is ini the root of the CD. I have no idea whether this will fix your firefox problems or not, just something to try

  3. #3
    Twansparant Twandeman's Avatar
    Join Date
    May 2004
    Location
    Amsterdam
    Posts
    197
    Hi Northcode,
    This post is from time ago, I know.
    I tried what you suggested, because I'm having the exact same problem, I just want to open an html page on my cd-rom from my standalone projector, because the html-page isn't online anymore, and because you can't expect that everyone has an internet connection. Can't this be done? I tried your code:
    Code:
    drv = _url.substr(8,1);
    getURL("file://" + drv + ":\\website\\portfolio.html");
    Instead of opening a blank window, nothing happens anymore.
    Is this only a firefox issue?
    Thanks anyway!
    Toine Kamps | Design & Coding
    toinekamps.com

  4. #4
    Twansparant Twandeman's Avatar
    Join Date
    May 2004
    Location
    Amsterdam
    Posts
    197
    Toine Kamps | Design & Coding
    toinekamps.com

Posting Permissions

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




Click Here to Expand Forum to Full Width

HTML5 Development Center