Problem (and solution) : getURL() in a Flash projector fails in Firefox

Posted October 11, 2006 1:28 pm
Filed under: AS3, ActionScript, Articles by Paul, Flash, Flex, Web Browsers

On Windows, using getURL() or a similar approach to open an HTML page from a SWF running in the standalone Flash Player (such as a Flash projector file running on a CD-ROM) doesn’t work if the user has Firefox set as their default browser. Here we’ll take a look at what’s causing the problem and how to work around it.

Note: based on some helpful feedback the code was revised on Oct. 30, 2006 to be more cross-platform-friendly.

As a followup to a question about opening local and remote resources in ActionScript, I was asked why a SWF which had been made into a projector (a standalone executable file) wasn’t able to open an HTML page using getURL() when the user’s default browser is Firefox. One initial idea was that it might be related to the security restrictions added in Flash Player 8, which (by default) make it so a SWF which is running off a user’s local computer can only access local resources or network resources, but not both. However, as the documentation points out, a SWF which has been published as an executable file isn’t subject to the same restrictions. (And I actually tested it out to confirm that’s the case.)

So here’s the situation: imagine you’re creating a SWF file to use as a menu on a CD-ROM. It will have several buttons, some of which will open HTML pages that are also on the CD-ROM. That sounds easy enough—using the getURL() function in ActionScript 2 (or the equivalent flash.net.navigateToURL() function in ActionScript 3.0), you can specify a relative url (basically just the file name) of the HTML page you want to open, and when the user clicks the button, Flash Player hands the url off to the operating system and the HTML page is opened in the user’s default browser. So if you want to open a file named “test.html” which is at the same level in the file system as the SWF executable, you would use this code (ActionScript 2):

// assume the button's instance name is myButton

myButton.onRelease = function()
{
    getURL("test.html", "_blank");
};

or this code (ActionScript 3.0):

// assume the button's name is myButton

import flash.events.MouseEvent;
import flash.net.*;

function openPage(event:MouseEvent):void
{
    var request:URLRequest = new URLRequest("test.html");
    navigateToURL(request, "_blank");
}

myButton.addEventListener(MouseEvent.CLICK, openPage);

Assuming the user’s default browser is Internet Explorer (or a version of Netscape/Mozilla prior to the ones based on Firefox), this works as you would expect it to: the user clicks the button, and the page “test.html” opens in the browser.

However, if the user’s default browser is Firefox (or, I suspect, one of the recent Netscape versions based on Firefox) then the page does not open. Instead, one of a few possible things happens. On my system, Firefox opens with two tabs. The first tab is blank, and the second contains a security warning (something about not being able to change the location of the My Documents folder). This is very possibly because I was testing it from my hard drive, rather than from a CD-ROM drive. On other people’s systems, from what I’ve heard, the browser opens with a blank tab and a tab which is the result of a Google “I’m feeling lucky” search based on the name of the file (which is the default action when you enter keywords rather than a valid url in the browser’s address bar).

Note: this problem isn’t just limited to getURL() — it also applies to other methods which load a url, such as LoadVars.send().

So what’s going on, and more importantly, how do we make it work so that we can use SWF menus to open web pages on a CD-ROM? After doing a little research, I learned first of all that Adobe is aware of the situation, and that in fact it’s not a Flash Player bug at all. It turns out that this is due to a Firefox bug (well, an out-of-control feature) based on how Firefox handles a url which is passed to it as a command-line parameter.

According to the bug report, when you call Firefox on the command line, you can pass it multiple urls separated by pipe (|) characters and it will open each one in a separate tab. So if you issue a command like this:

firefox -url "http://www.yahoo.com/|http://www.google.com/"

Firefox opens a new browser window, with Yahoo in one tab and Google in another.

Going back to Flash Player, when you call the getURL()/navigateToURL() function with a relative url (something like “test.html”), Flash Player actually constructs an absolute url which is what it passes to the browser. So when our code says getURL("test.html", "_blank"), Flash Player turns that into something like this in the (Windows) operating system:

firefox -url "file:///d|assets\test.html"

Notice the magical pipe character (|) where you or I would probably put a colon (i.e. “file:///d:\assets\test.html”). The pipe syntax is legal—Firefox just assumes that a colon will be used instead. So when Flash Player constructs an absolute url and sends it to Firefox, Firefox sees the pipe character and says “hey, they want me to open two tabs, the first with the url “file:///d” and the second with the url “assets\test.html”. Hence we see a browser window with two tabs, with the second containing the result of a Google search for “assets\test.html”.

Note: according to the same bug report, this has been fixed for the “Deer Park” version of Firefox, which I believe is Firefox 2.0, so once that browser is out and spread throughout the world, this won’t be as much of an issue. But I won’t be holding my breath…

Interestingly, on the ActionScript end of things the problem stems from the fact that Flash Player is constructing an absolute url to send to the browser, and that url contains a pipe character. When you specify an absolute url in your getURL()/navigateToURL() call, Flash Player just passes that url to the browser unmodified. Of course that’s what we’d expect for a remote web address, like “http://www.google.com/”, but it works just the same for local “file:///” urls. So to work around the Firefox bug, what we really need to do is construct the absolute url ourselves in ActionScript, and use that url (which, again, will get passed to the browser unmodified). The big question, of course, is how we can figure out the absolute path of a file on a CD-ROM when we don’t necessarily know the drive letter of the user’s CD-ROM drive.

Fortunately, ActionScript comes to our rescue. Every MovieClip object (every DisplayObject in AS3) knows the url it was loaded from. You can access this as the _url property in ActionScript 2, or as the url property of the DisplayObject’s loaderInfo property in ActionScript 3.0. Usually, for a SWF in a web page, this will be the url of the SWF file, of course, but when a SWF is running locally (even when it’s in an executable/projector) that property contains an absolute “file:///” url with the path of the SWF file on the file system. For example, consider this code, on a keyframe on the main timeline, running in a SWF projector (an EXE file) on a CD-ROM:

// Assumes there's a dynamic text field on the stage named output_txt

// AS2
output_txt.text = this._url; // output_txt contains "file:///E|/assets/trial.exe"

// AS3
output_txt.text = this.loaderInfo.url; // output_txt contains "file:///E|/assets/trial.exe"

Going back to our SWF CD-ROM menu example, if the HTML page we want to open is in the same folder as the SWF projector, we can just generate our own absolute url by getting the SWF’s url, chopping off the name of the SWF, replacing the “|” with a colon, and adding the name of the HTML page. (Or, for a more complex case, we can use the SWF’s url to determine the “base” url, and then use that to generate absolute urls for files in other folders etc.)

Here is the code for a working version of this (ActionScript 2):

// code on a keyframe on the main timeline

var swfUrl:String = _root._url;
var lastSlashIndex:Number = swfUrl.lastIndexOf("/");
var pipeIndex:Number = swfUrl.indexOf("|");
var baseUrl:String;
if (pipeIndex >= 0)
{
    baseUrl = swfUrl.substring(0, pipeIndex);
    baseUrl += ":";
}
else
{
    baseUrl = "";
}
baseUrl += swfUrl.substring(pipeIndex + 1, lastSlashIndex + 1);

myButton.onRelease = function()
{
    var targetUrl:String = baseUrl + "test.html";
    getURL(targetUrl, "_blank");
};

And here’s a working version in ActionScript 3.0:

// code on a keyframe on the main timeline

import flash.events.MouseEvent;
import flash.net.*;

output_txt.text = this.loaderInfo.url;

var swfUrl:String = this.root.loaderInfo.url;
var lastSlashIndex:Number = swfUrl.lastIndexOf("/");
var pipeIndex:Number = swfUrl.indexOf("|");
var baseUrl:String;
if (pipeIndex >= 0)
{
    baseUrl = swfUrl.substring(0, pipeIndex);
    baseUrl += ":";
}
else
{
    baseUrl = "";
}
baseUrl += swfUrl.substring(pipeIndex + 1, lastSlashIndex + 1);

function gotoTestHtml(event:MouseEvent):void
{
    var targetUrl:URLRequest = new URLRequest(baseUrl + "test.html");
    navigateToURL(targetUrl, "_blank");
}

myButton.addEventListener(MouseEvent.CLICK, gotoTestHtml);

Of course for the AS3 version you could use regular expressions for the finding and replacing—but in this case it’s simple enough, and perhaps more efficient, to not use them.

If you’d like to try it out for yourself, you can download FLAs for these two versions (45 KB .zip).

By request, I’ve also made a version of the FLA in Flash MX 2004 format (31 KB .zip).

You can leave a comment, or trackback from your own site.

91 Comments so far


  1. Ali is reported to have said:

    Thank you, Paul. I tried to find an answer for this problem in every place I know but couldn’t find before. Now you solved it pretty cleanly.
    I believe this will save a lot of people’s time out there who may not aware of this solution.


  2. Adrian is reported to have said:

    Great explanation and research. Thanks


  3. Han Sanghun is reported to have said:

    I haven’t experienced this problem yet.
    But this tip will save my time and effort someday.
    thanks.


  4. Ryan is reported to have said:

    aaaaahh.. thanks Paul.. I’ve been pulling my hair out with this for a while.. I’m glad you’ve found a solution.. thaanks!


  5. danielyuen.hk Blog : links for 2006-10-12 is reported to have said:

    […] pt: to active all activeX object (tags: ie activeX flashplayer) Problem (and solution) : getURL() in a Flash projector fails in Fir […]


  6. whitney is reported to have said:

    i realize that this is a fix for firefox, but it seems to screw up the link in safari.

    am i missing something elementary?

    thanks :)


  7. Paul is reported to have said:

    Hi Whitney,

    Actually, I’m the one who was missing something elementary — the way I wrote the code it assumed that the url would always have a pipe character in it, but of course on OS X (and Linux?) it won’t, so it actually broke things for non-Windows OSes. I’ve updated the code (above) to perform better from a cross-platform standpoint (and I tried it out on my Mac to make sure it actually works =).

    Anyone who can test it out on Linux (FP 7 and 9) please feel free to let me know how it works.

    Thanks for the feedback!


  8. downview » Blog Archive » getURL problem in Firefox is reported to have said:

    […] he problems began. It took a few hours to actually work out what the error was and I found a *very* useful page by Paul Robertson that solved the issue. T […]


  9. Niall Flynn is reported to have said:

    Having a similar problem using the getURL method to open PDFs, no probs in IE, but no joy with Firefox. The urls for each PDF are feed to the swf via a PHP script and stored in hidden text fields, then called on press. I have tried everything, any help would be most appreciated.


  10. Sigkill(9) is reported to have said:

    Paul,
    My hat is off to you.

    1000000.times do print “Thank you Paul!\n”

    SK9


  11. Todd is reported to have said:

    Everything makes sense, but I am still getting a blank page in a new tab with firefox. And I can’t get the sample to open since I am using MX 2004, can you back publish with flash 8?


  12. Alex is reported to have said:

    Paul, nice job on this fix. I have implemented this on a file that I too was having errors with in Firefox on the PC. I opted not to include the Macintosh projector with the standard getUrl() before I found out about this issue because the links were not working only on the Pentium based Macs, seemed fine on my G5, both running Firefox.

    After further testing we found the links not to be working on all PCs, with the latest version of Firefox. Your fix works well here.

    With the this technique I still found that the Pentium based Mac still could not access the file. It appears to translate the base url into file:/// as opposed to Volumes/ as on the G5.

    Has anyone tested this fix on a Pentium based Mac and had success with this technique? Paul, any ideas from your creative problem solving skills?


  13. Paul is reported to have said:

    Todd:

    I’ve added a version in MX 2004 format for you.


  14. Dan is reported to have said:

    This was very well explained and saved my hide on a project. Excellent work!


  15. Bitey is reported to have said:

    Thank you, thank you, thank you! That’s been driving me nuts!


  16. Martin is reported to have said:

    This is not working for me. The main reason might be that i am not working on a CDROM nor any executable, but a Christmas Calender which has 24 gates that redirects to their own url.

    The calender works great in IE 7.0, publiced to Flash Player 8.

    In Firefox 1.5.0.8 it won’t redirect at all, even with the code here. As a note the code listed here works great in IE 7.0.

    If i publish for Flash Player 7 it works in Firefox, but it looks horrible. The gates resize when i click them for no apparent reason.

    Any ideas why the listed code works in IE 7.0 but not in FF 1.5.0.8?

    Best regards


  17. Nazar is reported to have said:

    Thank you SO Much! I was getting so upset that my project won’t work with Mozilla. But with your incredibly helpful script everything works perfectly!

    Lots of Respect!


  18. Jai is reported to have said:

    You can not believe how happy you have made me. I thought I was going to have to have two versions one calling exe’s on pc and geturl on mac.

    Thank you so much for working that out.


  19. Dale is reported to have said:

    I’m using the AS2 version with Flash 8. Works well, unless the link has an anchor in it (e.g. “test.html#02”) in which case it completely ignores the anchor. Anyone know of a solution?


  20. Rajiv Sarna is reported to have said:

    Thanks Paul, this is indeed very helpful.

    In my case, i was looking for a code, where a projector file should close automatically, when i open it and my default html file gets loaded. I was trying to figure the workaround for the same and your code indeed helped me for my problem.

    In AS 2, i just modified one area of your code from -

    myButton.onRelease = function()
    {
    var targetUrl:String = baseUrl + “test.html”;
    getURL(targetUrl, “_blank”);
    };

    To -

    var targetUrl:String = baseUrl + “xyzFolder/test.html”;
    getURL(targetUrl, “_blank”);
    fscommand(‘quit’)

    And this code works fine.

    Thanks.


  21. Ravi is reported to have said:

    Hai paul, excellent,Its working well, i had search for this code for long time, I save lot of time in my project implimentation, if u explain how the code is working,then its great enough,

    thank you once again.


  22. Matt is reported to have said:

    Hi Paul, thanks ever so much for documenting this, it’s saved me hours of agony! Good job :)


  23. Jean Baptiste is reported to have said:

    Thank you - you saved my day…


  24. ThePatrix is reported to have said:

    God Bless you sir….I was almost to the point of scrapping my whole project and starting over…this fix works perfectly and I am able to continue with my project :)

    Sincerely,
    ThePatrix


  25. fat matt is reported to have said:

    Awesome! You’ve just saved me from five simultaneous heart attacks (if that’s even humanly possible)…


  26. Hangun’s World blog » Blog Archive » 프로젝터에서 getURL()이 실행되지 않을때 is reported to have said:

    […] 출처 : Words, punctuated […]


  27. Charles is reported to have said:

    Thanks alot Paul… I am working on my interactive CV and this problem really killed my spirit. Thank you alot.


  28. Question about flash and web building - MacNN Forums is reported to have said:

    […] I bet relative paths in Flash work the same way as any other graphical web authoring app. This page may be helpful to you. You may also want to try posting your question in the Developer forum instead. […]


  29. Eddie Prislac is reported to have said:

    Thanks for the post, this really helped- I’m running firefox 2.0, and I can attest that this is still a problem, as I found out to my chagrine today. What’s weird is that firefox is not even my default (I am using windows vista with IE7 and FF2 installed) yet Flash projector still opens the pages in FF. Crazy, huh?


  30. Xavier Segura is reported to have said:

    Thanks a lot!
    you saved my job!


  31. Dan is reported to have said:

    Awesome post!! I have less than 1 week to have my portfolio working and then I realized that my portfolio wasn’t launching the urls on certain browsers. It only took a few minutes to figure out where I needed the code to go and then it worked like magic. Thank you!


  32. Coria is reported to have said:

    Thank you Paul!


  33. Adobe - Flash Actionscript is reported to have said:

    Kramer auto Pingback[…] I have just found this http://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/ which appears that it only happens when the user has firefox as their default browser. I have changed mine to IE to test and it works fine […]


  34. StumbleUpon » Your page is now on StumbleUpon! is reported to have said:

    Kramer auto Pingback[…] Your page is on StumbleUpon […]


  35. is there a getURL Firefox workaround - kirupaForum is reported to have said:

    Kramer auto Pingback[…] I found a solution and its worth reading http://probertson.com/articles/2006/…refox-problem/ […]


  36. Ralph Ferrand is reported to have said:

    Thanks a million Paul - you have saved my credibility with a client.
    I can’t thank you enough.
    Kindest regards,
    Ralph


  37. David McClelland is reported to have said:

    This was just the bit of info I needed - your explanation was clear and precise. Justifiably high on the Google results list for “getURL() in projector”.

    Thanks for contributing to the practice!


  38. Web site on CD ROM will not run in Firefox - MozillaZine Forums is reported to have said:

    Kramer auto Pingback[…] Posted: Apr Thu 12th 2007 11:36am      Googling flash geturl cd returns a few thousand articles. This one looked pretty relevant, it offers a workaround passing a more complete URL using ActionScript: Problem (and solution) : getURL() in a Flash projector fails in Firefox @ a bunch of Words, punctuated - by Paul Robertson (http://probertson.com/). Does it help? […]


  39. Peter is reported to have said:

    Brilliant! I have searched long and hard for this before to no avail and had to refuse work from client (silly, really, it should be so simple to do a CD menu launcher). Great work, thanks a million.


  40. seven (nivas.hr blog) is reported to have said:

    […] Helpful resources: […] Problem (and solution) : getURL() in a Flash projector fails in Firefox […]


  41. cesare is reported to have said:

    Unbelievable, this is exactly the fix I was looking for, thanks for taking the time and sharing your expertise!!


  42. Flash projector 無法geturl() « 一個記憶的場景 is reported to have said:

    […] Flash projector 無法geturl() http://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/ […]


  43. Free Flash Forums is reported to have said:

    Kramer auto Pingback[…] I found a solution and expalnation why the getURL is not working in FF […]


  44. Isabelle is reported to have said:

    Thanks a lot for your help.
    I have a problem with “mailto”. It doesn’t work with your function. Please could help me?
    Best regards,
    Isabelle


  45. Adobe - Flash Actionscript is reported to have said:

    Kramer auto Pingback[…]  | Quote  | Top  | Bottom I have just found thishttp://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/which appears that it only happens when the user has firefox as their default browser.I have changed […]


  46. Edwin is reported to have said:

    Thank You very much. Do you have a place for donations. Well deserved for the clarity of the explanation and the seriousness of the research


  47. Macromedia Flash: Opening PDF from Flash application opens Firefox blank window is reported to have said:

    Kramer auto Pingback[…] Firefox rather than flash.Here’s an interesting article that covers the problem with a proposed fix.http://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/   function showSignUp(id) { var select = document.getElementById(“answer”+id); if […]


  48. SG is reported to have said:

    I was also having same problem. But can you tell me If I want to open a browser window (HTML page) of a particular size from my flash projector file, how can i do that?


  49. DG is reported to have said:

    I second that question about resizing a browser window using the above method. how do you combine the two? thanks again.


  50. XClaus: octubre 2006 is reported to have said:

    Kramer auto Pingback[…] reencuentro con mi Blog… todo salio bien.. el problema con flash y que no me dejaba escribir se resolvio :D El problema era que al ejecutar un exe de flash que abria un URL en un CD no lo abria.. lo que […]


  51. [Flash 8] - [stuff]externe dateien offline in browser laden - Flashforum is reported to have said:

    Kramer auto Pingback[…] Robertson hat eine andere Loesung gefunden: http://probertson.com/articles/2006/…refox-problem/ Der Trick ist, dass man Firefox eine absolute Url braucht, bei der das Pipezeichen | durch : […]


  52. Flash Kit Community Forums - Problem opening html files in Firefox is reported to have said:

    Kramer auto Pingback[…] we are trying to open some html files from our flash projector (basically like an offline website). […] Take a look at this […]


  53. Zotyo is reported to have said:

    Thank you very much!
    This “tutorial” absolutely solve my problem! Everything is clear and understandable. :)
    Nice work!
    Z


  54. Director Online Forums :: General Director Questions :: Downloadable pdf, jpg is reported to have said:

    Kramer auto Pingback[…] reading local files (like off a CD), be sure to read this article if you have issues with Firefox: [probertson.com] […]


  55. getURL FireFox problem - Page 3 - ActionScript.org Forums is reported to have said:

    Kramer auto Pingback[…] this a solution I found and worth reading […]


  56. Flashlibrary : Call to possibly undefined method getURL is reported to have said:

    Kramer auto Pingback[…] The code snippet above was taken from here […]


  57. Maria Dalva is reported to have said:

    Wow!!! Thank you so much! :o)


  58. After-Hours ~ Ver tema - CDROM autoejecutables desde contenido html y flash is reported to have said:

    Kramer auto Pingback[…] Robertson, en su blog, l explica porque sucede y muestra como solucionar esta parte. El link: http://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/ Resumiendo: se puede usar dentro del proyector lo descrito previamente, que dicho sea de paso, […]


  59. [Rsolu]probleme getURL _blank - Centre de Formation Flash - Forums Adobe Flash is reported to have said:

    Kramer auto Pingback[…] une projection sur lequel je m'arrache les cheveux cause de IE et ses scurits de M***** :lienSi je trouve la soluce je […]


  60. Joel Brown is reported to have said:

    I have worked through the example above, and it works wonderfully for the PC environment. For some reason (an I am not an actionscript expert by any means), it doesn’t act the same in the Mac environment… has anyone got any ideas as to why?

    Cheers
    Joel


  61. as3 - SWiK is reported to have said:

    Kramer auto Pingback[…] Problem (and solution) : getURL() in a Flash projector fails in Firefox, a bunch of Words, punctuate… […]


  62. La communaut secrte :: Voir le sujet - is reported to have said:

    Kramer auto Pingback[…] http://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/ Essaye de voir si a t’aide. […]


  63. Corey is reported to have said:

    This might sound like a silly question ( I know only a very small amount about Actionscript and such. ) but is there an XML solution like the one above.

    Please ignore this question if it makes no sense, just trying to solve a problem.

    Thanks
    Corey


  64. DBP is reported to have said:

    I, too, am wondering if there’s a good way of adapting this extremely useful workaround for the many instances where html is used not on a button action, but as part of dynamic text.

    There’s the getURL (“javascript:…”) method to call the function— but this requires including the function within an .html page containing the flash movie.

    Any ideas of how to implement this workaround using Flash standalone player? I’m developing a cross-platform CD, and none of the links will launch in Mac-Firefox w/o this lovely workaround—but alas, how to call the function?

    A lot of us are developing using xml and/or arrays of info, since everything is component-based nowadays and you can barely include data otherwise…

    Many thanks!


  65. getURL problem - SitePoint Forums is reported to have said:

    Kramer auto Pingback[…] Firefox set as your default browser? http://probertson.com/articles/2006/…refox-problem/ __________________ Ben Partch - Metalpedia - CSS Basics Search-This - Not my site, but I like […]


  66. Ronal is reported to have said:

    How to make it works when I use getURL(“http://www.yahoo.com”,”_blank”).

    It works for local file as your sample.

    thanks before


  67. FlashFocus.nl - Flash projector is reported to have said:

    Kramer auto Pingback[…] op dat moment natuurlijk. En blijkbaar ook op voorwaarde dat IE als standaard browser is ingesteld. http://probertson.com/articles/2006…irefox-problem/ […]


  68. Troy Spetter is reported to have said:

    I just started using ActionScript 3.0 and this solution help me greatly. Thanks for including the examples in 2.0 and 3.0. It helps us new to 3 to make the conversion.


  69. Erzo is reported to have said:

    thank you very much for all you explications,
    I don’t know what to tell you,
    simply, you are a god

    thank you again.


  70. orangered is reported to have said:

    This was a great help! Thanks a lot! You stopped my hair turning gray … for the day … thanks a lot.


  71. Haresh Shah is reported to have said:

    Thanks a lot mate…!!

    I would have kissed your hand, had I met you..!! :-)

    This is what I was searching for 8 hours and thanks to your detailed explanation and solution, it solved my problem in 8 minutes..!!

    I am very thankful to you yaar…thanks a ton…!!!


  72. orangered is reported to have said:

    Hello again,

    i have just a question. Is it possible that Firefox/2.0.0.9 - Version works different? Everything worked but now I have the two windows open again … or did i something wrong? Everybody out here who has an idea? Would be great.


  73. a.J. Leong is reported to have said:

    Hi Paul,

    Thanks for your lovely solution.
    i get my problem solved !..
    actually i am using loadmovie() command which facing the same problem as well..

    i think you saved plenty of people out there from trouble and i am just one the lucky one!

    Good job ! appreciate for your hardwork ; )

    a.J.


  74. Mika is reported to have said:

    YOU JUST HAVE SAVED MY LIFE!! That’s the article I needed, now my SWF runs at last… Thank you so much!


  75. getURL FireFox problem - Page 3 - ActionScript.org Forums is reported to have said:

    Kramer auto Pingback[…] is a solution I found and worth reading http://probertson.com/articles/2006/…refox-problem/ __________________ For fear is nought but the surrender of the helps that come from reason; and […]


  76. Chris is reported to have said:

    I have a similar problem. My client delivers a package of files (swfs and html) to their users for desktop usage. The user launches the provided html which embeds the swf. (btw - we set a config file to allow Trust, enabling internet access as well as local access). The root swf is published for Flash Player 7. For some reason we can’t seem to call any javascript in the container html when browser is IE. Since is published for FP7, we don’t have the option of ExternalInterface. JS calls using getURL work fine in all other browsers. :(


  77. Adding a link to a button in Flash 8/CS3 is reported to have said:

    Kramer auto Pingback[…] as well? I have found a couple of things on the web regarding a bug in firefox, and one in IE: http://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/http://blog.madebyderek.com/archives/2007/09/11/fscommand-and-geturl-bug-in-flash-player-9/as well […]


  78. Matt is reported to have said:

    Hi there,

    I have tried using this but it doesn’t seem to work when my .swf is embedded and ran in Firefox, even when uploaded. It works when running in Flash Player standalone but otherwise no luck. Works in IE tho, but always did.

    Any ideas?


  79. Sidi is reported to have said:

    in ie6, error, i don´t understand.

    Please help!


  80. Paul is reported to have said:

    A couple of people have mentioned having problems on Internet Explorer. I’m not sure if this is related, but I thought I’d pass it along because it could be. I just learned today that this is a known bug that is new in Flash Player 9r115 (currently, the latest Flash Player release). Because of this bug, calling a “javascript:…” url in getURL()/navigateToURL() is broken when it’s used in a SWF running locally (that is, off the user’s hard drive rather than from a web site) in Internet Explorer 7.

    There’s also another issue that prevents getURL()/navigateToURL() with “javascript:…” urls from working in IE6 and 7 for web content when the HTML page and the SWF file are in different domains.

    Here’s a link with a bit more info:
    http://kb.adobe.com/selfservice/viewContent.do?externalId=kb403072


  81. booota is reported to have said:

    hey buddy…
    thanks for this tutorial…
    i want to ask that i hav two flash movies…
    1 has only menu and is embedded in php (menu.swf)….
    other is having menu as well as some frames (index.swf)…
    menu.swf has 5 links… 1 is of the same page and disabled… when i clik on any other link… it loads index.swf basically its html file using geturl and method is ‘get’ to pass a variable ‘id’…
    question is how can i get the value of id in the first frame of index.swf.
    i hav used flashvars and swobjects but in vain…
    can u tell me how can i do that within swf…. something if i can grab the url from address bar and then load the variable id in first frame…


  82. combining getURL command with javascript to control popup windows - ActionScript.org Forums is reported to have said:

    Kramer auto Pingback[…] and need to open windows of a browser to contain java created content. I have been to: http://probertson.com/articles/2006/…refox-problem/ This loads the page required from the CD but has the URL bar, back and forward arrows, goolge […]


  83. matthewstroh is reported to have said:

    I came to this page looking for help with getURL not working in Firefox on the web. I eventually found out that the following code helped by telling the command to open in ‘self’ and use ‘get’. Firefox and Safari on Mac didn’t have problems with this syntax.

    on (release) {
    getURL(‘http://www.yoursite.com/test.html’, ‘self’,’get’);
    }


  84. WireFusion :: View topic - Run from flash cdrom is reported to have said:

    Kramer auto Pingback[…] this can be of help: http://probertson.com/articles/2006/10/11/geturl-flash-projector-firefox-problem/ /Johan_________________Johan Akesson […]


  85. Joe is reported to have said:

    Very very very helpful! Thanks :)


  86. Firefox no me abre _blank + Cristalab is reported to have said:

    Kramer auto Pingback[…] Parece que hay muchsima documentacin al respecto en google… ESTO ha de ser lo que buscas (est en ingls) …Otra solucin sera hacerlo con los dichosos PopUps, […]


  87. getURL in firefox - Ultrashock Forums is reported to have said:

    Kramer auto Pingback[…] Are you running from a projector? http://probertson.com/articles/2006/…refox-problem/ […]


  88. Justin is reported to have said:

    Hi Paul….Like whitney said earlier The fix breaks on Mac OS…where can I get the updated code you spoke of? Thanks so much….


  89. Michael is reported to have said:

    Thanks for that fix…


  90. Nuestra ración de infierno | 2flash2furious, un blog de [Q] interactiva :: diseño gráfico, web & multimedia is reported to have said:

    […] Yo quiero a Paul Robertson, que además da una fantástica explicación del problema soluciones en AS2, AS3 y enlaces a otros […]


  91. FlashBG • View topic - Нещо непонятно: getURL в EXE is reported to have said:

    Kramer auto Pingback[…] javax on Thu Oct 12, 2006 11:02 днес попаднах на това: http://probertson.com/articles/2006/10/ … x-problem/ …you were […]

Add your comment





Comment notes

Please keep comments on topic. Comments that are inappropriate or offensive will be edited or removed.

Paragraphs and line breaks are automatically converted to HTML, and quotation marks are converted to “smart” quotes.

The following XHTML tags can be used: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> . All others will be removed.

Articles by Type

Articles by Topic

Random Reading

Currently...

Subscribe