Hey Bernd,
You can't "morph" background images. If you want image crossfades, you
need two separate elements (either <img>'s or anything with the proper
background image in its style), positioned inside your container, with
proper z-index to look like backgrounds respective to other contents,
and then you cross-fade those.
Perhaps something like:
<!-- btw, div="1" is invalid: you can't start with a digit -->
<div id="div1" class="crossBacks">
<img src="img/pfeil_klein_subnav_links.jpg" class="back links" />
<img src="img/pfeil_klein_subnav_rechts.jpg" class="back rechts"
style="display: none;" />
<div class="contents">Background-image</div>
</div>
And some styling that may look like this:
.crossBacks { position: relative; with: 150px; }
.crossBacks .contents { z-index: 42; }
.crossBacks img.back { position: absolute; top: 0; z-index: 0; }
.crossBacks img.back.links { left: 0; }
.crossBacks img.back.rechts { right: 0; }
And then, the cross-fade would look something like this:
var container = $('div1');
container.down('.back.links').fade();
container.down('.back.rechts').appear();
Or something along these lines…
'HTH
--
Christophe Porteneuve aka TDD
[EMAIL PROTECTED]
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---