Results 1 to 8 of 8

Thread: Lightbox from flash does not work with iExplorer

  1. #1
    Join Date
    May 2007
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Lightbox from flash does not work with iExplorer

    Hi there,

    I have just updated my homepage with a swf file on the html based template of my homepage. The swf calls for the lightbox javascript from three buttons (movieclips, really). It works swell on all my browsers on my mac (opera, firefox, safari and camino) as well as on firefox on pc. But of course iExplorer refuses to work...

    http://www.kaaresmith.dk/portraet_gb.html

    Does anyone have an idea of what the problem is? I mean, lightbox called from a normal html-based button works fine with iExplorer, so what is the issue when called from a swf-file?

    I am not really a coder, more of a copy-and-paste-kind-of-guy so I don't have a clue as to what be looking for.

    I hope I have provided enough information, otherwise I'll promptly write back.

    Kaare

  2. #2
    Join Date
    Jul 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hi everybody ! (I'm a new user of this forum)
    I have exactly the same problem of photoguy1601. Does anybody have an answer ?

    Thanks

  3. #3
    Join Date
    Jul 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    For information here is the code:

    JavaScipt:

    <script language="JavaScript">
    function LightboxDelegate1(url,caption){
    var objLink = document.createElement('a');
    objLink.setAttribute('href',url);
    objLink.setAttribute('rel','lightbox[paysages]');
    objLink.setAttribute('title',caption);
    Lightbox.prototype.start(objLink);
    }
    </script>

    <script language="JavaScript">
    function LightboxDelegate2(url,caption){
    var objLink = document.createElement('a');
    objLink.setAttribute('href',url);
    objLink.setAttribute('rel','lightbox[portraits]');
    objLink.setAttribute('title',caption);
    Lightbox.prototype.start(objLink);
    }
    </script>


    html:

    <a href="images/paysage1.JPG" rel="lightbox[paysages]" title="Montagne"></a>
    <a href="images/paysage2.JPG" rel="lightbox[paysages]" title="Lac L&#233;man"></a>

    <a href="images/portrait1.JPG" rel="lightbox[portraits]" title="Claude, Vidy"></a>
    <a href="images/portrait2.JPG" rel="lightbox[portraits]" title="Bernard, Vidy"></a>


    ActionScript in Flash

    on (press) {
    getURL("javascript:LightboxDelegate1('images/paysage1.JPG' , 'Montagne')");
    }

    on (press) {
    getURL("javascript:LightboxDelegate2('images/portrait1.JPG' , 'Claude, Vidy')");
    }


    I want each button to open a gallery in the lightbox. But now when I click on the button I have only a dark screen and no lightbox.

    Thanks
    Last edited by NicoJ; 07-01-2007 at 08:36 PM.

  4. #4
    Join Date
    May 2006
    Location
    Alaska
    Posts
    163
    Thanks
    5
    Thanked 2 Times in 2 Posts

    Default

    Well, hehe. Javascript:blahblahblah, might not be what you're looking for, because I think it will open a blank page with that, since it's being done by the AS, not the JS. What you want for AS is external interface. You have to import something, then do externalInterface.call("jsfunc","param1","param2"); and you can have as many parameters as you want. Although if you problem is only with IE, you could add an FSCommand because it only works in IE, but I forgot quite how you use it.

    PS: It's called JavaScript, NOT Java. Java is a different programming language.

  5. #5
    Join Date
    Jul 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    The problem is only with ie. I try with Firefox and it works.

    How to add a FSCommand ? It can work with that command ? (I'm a beginner...)

    Thanks:-)

  6. #6
    Join Date
    Jun 2007
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hiya! I'm having the exact same problem too! Works in every browser but IE. I get the grey transparency accross the screen and flash movie dissapears, but no js pop up windows with pics. urgh!

    I understand AS ok, but don't know js at all! Anyone have any ideas? What about this FSCommand? If anyone could help at all, it would be great!! It appears that everyone here with the same problems doesn't know js at all, but you would make our month if you could help us figure this out!

    Thank you in advance!!!!!!

    Quote Originally Posted by ??? View Post
    Well, hehe. Javascript:blahblahblah, might not be what you're looking for, because I think it will open a blank page with that, since it's being done by the AS, not the JS. What you want for AS is external interface. You have to import something, then do externalInterface.call("jsfunc","param1","param2"); and you can have as many parameters as you want. Although if you problem is only with IE, you could add an FSCommand because it only works in IE, but I forgot quite how you use it.

  7. #7
    Join Date
    May 2007
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hi,

    This link

    http://kb.adobe.com/selfservice/view...d=2#javascript

    seems to be the answer. I haven't tried, though, as it looks very complicated. But I think we are on the right track. Any experts on this matter?

  8. #8
    Join Date
    Jun 2007
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    http://www.dynamicdrive.com/forums/s...045#post102045 - check it out! Medyman figured it out!!!

Bookmarks

Posting Permissions

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