Are you serious? You'd have to have a plugin to animate a CSS property? Is
it just because it's the body background or does that apply to any
background in any element?
 
andy

  _____  

From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Karl Swedberg
Sent: Friday, September 07, 2007 9:55 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: How to fade only the background?


On Sep 7, 2007, at 9:20 AM, Andy Matthews wrote:


Or you could animate the backgroundColor property.



Yes, but you'll need the Interface plugin for that (at least iuitil.js and
ifx.js, IIRC). 
http://interface.eyecon.ro

Unfortunately, however, Interface overwrites jQuery's .animate() method,
rather than extending it, which has caused problems for some people in the
past. Don't know if that has been fixed/worked around or not. Maybe it's
worth a shot, though.


--Karl
_________________
Karl Swedberg
www.englishrules.com
www.learningjquery.com






  _____  

From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Erik Beeson
Sent: Friday, September 07, 2007 12:20 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: How to fade only the background?


Changing opacity affects all child elements. To only fade the "background"
just don't have the foreground be a child of it. You could use absolute or
relative positioning or negative margins or floats.

--Erik



On 9/6/07, howa <[EMAIL PROTECTED]  <mailto:[EMAIL PROTECTED]> > wrote: 


Hi,

The following code will fade the logo, instead of bg, e.g.


<html>
<head>
<script src="  <http://jqueryjs.googlecode.com/files/>
http://jqueryjs.googlecode.com/files/ 
jquery-1.1.4.pack.js" ></script>
<style> #bg{ width:600px; height:600px; background-color:blue; } </
style>
</head>
<body>

<script>
jQuery(document).ready(function() { 
jQuery("#bg").fadeTo("slow", 0.5);
jQuery("#logo").fadeTo("slow", 1.0);
}); 
</script>

<div id="bg">
<img id="logo" src="  <http://www.w3.org/Icons/w3c_main>
http://www.w3.org/Icons/w3c_main"; />
</div>

</body>
</html>

any workaround?

thanks.





Reply via email to