Search…

X3 Photo Gallery Support Forums

Search…
 
User avatar
bobhamers
Topic Author
Posts: 8
Joined: 14 Feb 2011, 15:06

Displaying div on top of gallery works in 2.5 but not in 2.6

14 Feb 2011, 15:41

Hi,

I just updated from 2.5 to the new 2.6 version and noticed that adding the wmode: transparent to the gallery template doesn't work anymore for displaying custom html elements on top of the gallery.


I've placed a div with some icons just above the start of the table in "index.gallery.phtml" using the following code:
Code
<style type="text/css">
        .icons img {margin-top: 15px; padding-right:8px; border-style:none;}
        .icons {padding-right: 17px; position: absolute; top: 0; right: 0; color: #fff;}
</style>
</head>
<body>
<div class="icons"> <!-- Icons: metrostation-3025 -->
    <a href="#/content/"><img title="Home" src="ico/home.png"></a>
    <a href="#/content/about/"><img title="About" src="ico/info.png"></a>
    <a href="http://www.facebook.com/xxxxxxx" target="_new"><img title="Facebook"src="ico/facebook.png"></a>
    <a href="#/content/contact/"><img title="Contact" src="ico/email.png"></a>
</div>
<table>
In v2.5 I used this code (only added wmode) which worked perfectly
Code
swfobject.embedSWF("<?php echo IV_PATH; ?>imagevue2.swf", "imagevue", "100%", "100%", "8.0.0", "<?php echo IV_PATH; ?>expressInstall.swf", flashVars, {allowScriptAccess: 'always', wmode: 'transparent', allowFullScreen: true, bgcolor: '#<?php echo $this->bkGrColor; ?>'}, {id: 'imagevue', name: 'imagevue'});
The new code has changed slightly, so I have added the wmode setting to the params var above the SWFloader:
Code
params={allowScriptAccess: 'always', wmode: 'transparent', allowFullScreen: true, bgcolor: '#<?php echo $this->bkGrColor; ?>'};
I see there is a separate one for IE that has wmode: opaque as the setting. I guess this has to do with the wmode changes relating to the new sharing services?

Am I doing something wrong here or is there another way I could solve this?

Any help would be greatly appreciated
Bob
 
User avatar
Nick
Imagevue Hitman
Posts: 2872
Joined: 02 May 2006, 09:13

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 00:04

Don't use transparent, just remove <-- if [IE] --> comments around the <script> with wmode:opaque and it will do the trick.

We thought we could go with opaque being set only for IE but the rabbit hole went deeper unfortunately.
firedev.com
 
User avatar
bobhamers
Topic Author
Posts: 8
Joined: 14 Feb 2011, 15:06

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 03:45

Just tried it, but still not working. The only thing that seems to have changed since 2.5 is that it's not responding to the wmode setting. When I inserted that in 2.5 it worked perfectly.
 
User avatar
mjau-mjau
X3 Wizard
Posts: 14452
Joined: 30 Sep 2006, 03:37

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 04:18

bobhamers wrote:Just tried it, but still not working. The only thing that seems to have changed since 2.5 is that it's not responding to the wmode setting. When I inserted that in 2.5 it worked perfectly.
Do you have a link to your gallery? It is not like we can control wmode or div on top of flash in any way - Either wmode is set or its not.
 
User avatar
bobhamers
Topic Author
Posts: 8
Joined: 14 Feb 2011, 15:06

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 04:20

 
User avatar
mjau-mjau
X3 Wizard
Posts: 14452
Joined: 30 Sep 2006, 03:37

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 04:43

Apparently, this is not wmode related. Just add z-index to your custom .icons {} class:
Code
z-index: 4;
 
User avatar
bobhamers
Topic Author
Posts: 8
Joined: 14 Feb 2011, 15:06

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 08:45

Ah, thanks! It works.

Should have thought of that, but didn't need it in the previous version so it just didn't occur to me.
Don't need the wmode change at all now.


Thanks a bunch!




EDIT:

Firefox does seem to need the wmode: opaque setting. Deleted the IE conditional and works like a charm cross browser!
 
User avatar
mjau-mjau
X3 Wizard
Posts: 14452
Joined: 30 Sep 2006, 03:37

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 10:49

We need to look into wmode again, and in which browsers/platforms it is applied.

The problem, is that there is a bug were mousewheel functionality is disabled when wmode is enabled.
 
User avatar
bobhamers
Topic Author
Posts: 8
Joined: 14 Feb 2011, 15:06

Re: Displaying div on top of gallery works in 2.5 but not in

15 Feb 2011, 11:15

Ah, I figured, because I keep getting a js error

'swfmacmousewheel' is undefined


Doesn't seem to hurt anything though.
 
User avatar
Nick
Imagevue Hitman
Posts: 2872
Joined: 02 May 2006, 09:13

Re: Displaying div on top of gallery works in 2.5 but not in

18 Feb 2011, 01:30

What is the browser you use? This error is appearing in IE but there are conditional comments around <script src> so you shouldn't be seeing this.
firedev.com
 
User avatar
mjau-mjau
X3 Wizard
Posts: 14452
Joined: 30 Sep 2006, 03:37

Re: Displaying div on top of gallery works in 2.5 but not in

18 Feb 2011, 06:27

pain wrote:What is the browser you use? This error is appearing in IE but there are conditional comments around <script src> so you shouldn't be seeing this.
It is not the <script src>, it is this:
Code
swfmacmousewheel.registerObject(attributes.id);
 
User avatar
bobhamers
Topic Author
Posts: 8
Joined: 14 Feb 2011, 15:06

Re: Displaying div on top of gallery works in 2.5 but not in

18 Feb 2011, 09:14

I'm using IE, but it's not the conditional script. It still happens when I remove it completely.
Also getting an error in Firefox though:

Error: swfmacmousewheel is null
Source: http://home.bobhamers.nl/#/content/
Line: 168

That has to do with the line mjau-mjau mentioned.
 
User avatar
Nick
Imagevue Hitman
Posts: 2872
Joined: 02 May 2006, 09:13

Re: Displaying div on top of gallery works in 2.5 but not in

18 Feb 2011, 09:50

Right, sorry about this, just added the fix to the code for the next version. If you want to get rid of this, do the following.

Replace

swfmacmousewheel.registerObject(attributes.id);
With:

if (swfmacmousewheel)
swfmacmousewheel.registerObject(attributes.id);

in /iv-includes/templates/gallery.index.phtml
firedev.com