How to detect browser is MAC Firefox and then load a gif but if not mac load an swf?

Discussion in 'JavaScript' started by eternal, Jun 30, 2008.

  1. #1
    I need an inline browser javascript to detect if the browser is MAC
    Firefox and to load a gif. If not mac firefox load an SWF.

    eg:

    detect if Mac firefox if yes load src="/content/flash/WYD03.gif"

    if other browser load src="/content/flash/WYD03.swf"



    is this possible?
     
    eternal, Jun 30, 2008 IP
  2. DomainCo.US

    DomainCo.US Well-Known Member

    Messages:
    2,124
    Likes Received:
    18
    Best Answers:
    0
    Trophy Points:
    100
    #2
    check for browser user agent... i'm not sure for the value for mac but for firefox it starts with Mozilla
     
    DomainCo.US, Jun 30, 2008 IP
  3. eternal

    eternal Guest

    Messages:
    48
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I would need it to be in the code NOT in the header as there are
    several swf's on one page and Mac Firefox is making the SWF on top of
    all other divs therefore not displaying the divs.

    see the problem here http://www.beamcreative.com/menutest.aspx

    index does not work with .swf files. I have a work around for all
    other browsers but Mac/Firefox has a bug that prevents SWF files to be
    at the bottom layer.
     
    eternal, Jun 30, 2008 IP