SitePoint Sponsor

User Tag List

Results 1 to 18 of 18
  1. #1
    Coding for Jesus LavernGingerich's Avatar
    Join Date
    Jul 2003
    Location
    Tennessee
    Posts
    607
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Javascript Z Index

    Hello,

    The image generated by this script is displaying on top of my lightbox images. Lightbox has a z-index of 100. .ssl has a z-index of 1.

    Code:
    <div class="ssl"><script language="Javascript" src="https://seal.godaddy.com/getSeal?sealID=208266540204d0ac0751271117b6d865417fab06486459262118408337"></script></div>
    See this page for an example:

    http://www.smokymtbarbecue.com/store...9899c1ad95df4e

    Then click on enlarge image.
    Yoder's Smoky Mountain Barbecue
    High quality barbeque smokers, pig roasters, and bbq pit grills.
    Pursuing Life Ministries - Jesus has saved me and given me hope.

  2. #2
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Reason for this is that Flash will always appear above HTML elements by default. Google for the wmode attribute to find out how to let HTML appear on top of Flash.

  3. #3
    SitePoint Member
    Join Date
    Nov 2006
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The only solution I have found for this is to place the flash on a seperate page in an iframe tag, and then place an object above the iframe.

    I've never heard of wmode before... I guess I'll have to look into it .
    Mike - Side project: Live Journal (blogging site).

  4. #4
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    No need for an iframe "hack". Just use the wmode attribute.

  5. #5
    SitePoint Member
    Join Date
    Nov 2006
    Posts
    16
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    wmode is part of flash, isn't it?
    Mike - Side project: Live Journal (blogging site).

  6. #6
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

  7. #7
    Coding for Jesus LavernGingerich's Avatar
    Join Date
    Jul 2003
    Location
    Tennessee
    Posts
    607
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I am not sure where to insert the code since I don't see object and embed tags.
    Yoder's Smoky Mountain Barbecue
    High quality barbeque smokers, pig roasters, and bbq pit grills.
    Pursuing Life Ministries - Jesus has saved me and given me hope.

  8. #8
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    There was a Flash element before on that page, can't see it now.

  9. #9
    Coding for Jesus LavernGingerich's Avatar
    Join Date
    Jul 2003
    Location
    Tennessee
    Posts
    607
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry. Yes, my GoDaddy ssl box is in Flash. But it's called with a javascript and doesn't have object and embed tags. Can you tell me how to use the wmode setting?
    Yoder's Smoky Mountain Barbecue
    High quality barbeque smokers, pig roasters, and bbq pit grills.
    Pursuing Life Ministries - Jesus has saved me and given me hope.

  10. #10
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    So, I assume that the JavaScript outputs the object tag. What you need to do then is to access this object tag with JavaScript and set the attribute wmode to transparent.

    To access you need some sort of DOM Inspector to see where the object tag is, it might even have and id you can use to access it.

    I can't see this flash in Firefox, which is a pity, since it has a great DOM Inspector built in.

  11. #11
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Though, come to think about it, wrap the script tag that outputs the flash in an element with an id. You could then access it
    Code:
    var flashObject = document.getElementById("wrapper_id").getElementsByTagName("object")[0];

  12. #12
    Coding for Jesus LavernGingerich's Avatar
    Join Date
    Jul 2003
    Location
    Tennessee
    Posts
    607
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Where are you looking?

    Check this page: www.smokymtbarbecue.com/store/index.php

    I found the id with the DOM inspector in Firefox. It's this: sitesealgd_t_small

    How can I access this object with javascript to set the wmode attribute? I am very limited in my knowledge of javascript.
    Yoder's Smoky Mountain Barbecue
    High quality barbeque smokers, pig roasters, and bbq pit grills.
    Pursuing Life Ministries - Jesus has saved me and given me hope.

  13. #13
    Coding for Jesus LavernGingerich's Avatar
    Join Date
    Jul 2003
    Location
    Tennessee
    Posts
    607
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Here is the source code for the GoDaddy box:

    Code:
    <div class="ssl"><script language="Javascript" src="https://seal.godaddy.com/getSeal?sealID=208266540204d0ac0751271117b6d865417fab06486459262118408337"></script></div>
    Yoder's Smoky Mountain Barbecue
    High quality barbeque smokers, pig roasters, and bbq pit grills.
    Pursuing Life Ministries - Jesus has saved me and given me hope.

  14. #14
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    In your slider.js file:
    Code:
    window.onload = function() {
      winOnResize(); // set initial position
      xAddEventListener(window, 'resize', winOnResize, false);
      xAddEventListener(window, 'scroll', winOnScroll, false);
      
      fixFlash();
      return;
    }
    
    function fixFlash() {
      var flash = document.getElementById("sitesealgd_t_small");
      
      if(flash != null) {
        var param = document.createElement("param");
     
        param.name = "wmode";
        param.value = "transparent";
    
        flash.appendChild(param);
      }
    }
    Not sure if this will work, give it a try and let me know if it does.

  15. #15
    Coding for Jesus LavernGingerich's Avatar
    Join Date
    Jul 2003
    Location
    Tennessee
    Posts
    607
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry, Pepejeria.

    I rewrote the code like this, and it works in Firefox and IE 7:

    Code:
    <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="https://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="100" height="60" id="sitesealgd_t_small" align="middle">
        	<param name="movie" value="https://seal.godaddy.com:443/flash/sitesealgd_t_small.swf?domainName=www.smokymtbarbecue.com" />
        	<param name="quality" value="high" />
        	<param name="wmode" value="transparent" />
        	<param name="bgcolor" value="#333333" />
          <embed src="https://seal.godaddy.com:443/flash/sitesealgd_t_small.swf?domainName=www.smokymtbarbecue.com" quality="high" wmode="transparent" bgcolor="#333333" width="100" height="60" name="sitesealgd_t_small" align="middle" type="application/x-shockwave-flash" pluginspage="https://www.macromedia.com/go/getflashplayer" />
        	 </object>
    Do you see a problem with doing it this way?
    Yoder's Smoky Mountain Barbecue
    High quality barbeque smokers, pig roasters, and bbq pit grills.
    Pursuing Life Ministries - Jesus has saved me and given me hope.

  16. #16
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ah, I thought you couldn't access that code... therefore the JavaScript solution.

    Yes, thats is a much better solution (adding the wmode attribute in the html code that is)!

  17. #17
    Coding for Jesus LavernGingerich's Avatar
    Join Date
    Jul 2003
    Location
    Tennessee
    Posts
    607
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I got it with the DOM inspector. : ) Thanks for the hint! And thanks for your kind help!

    Jesus is the way, the truth, and the life. John 14:6
    Yoder's Smoky Mountain Barbecue
    High quality barbeque smokers, pig roasters, and bbq pit grills.
    Pursuing Life Ministries - Jesus has saved me and given me hope.

  18. #18
    SitePoint Wizard Pepejeria's Avatar
    Join Date
    Jan 2005
    Location
    Too far up north
    Posts
    1,566
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You are welcome. Glad you sorted 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
  •