Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #13538
| Newsgroups | comp.lang.javascript |
|---|---|
| Subject | Re: Preloading PNGs & assigning as bkgd-image |
| From | "Evertjan." <exjxw.hannivoort@interxnl.net> |
| References | <f8s5p7dci7llr8kc70odlcq42fjilmbed4@4ax.com> <XnsA03CD5090445Eeejj99@194.109.133.133> <kim7p79v8m7aohvfgl623djeb9s0u9n84b@4ax.com> |
| Message-ID | <XnsA03E7DCE29B99eejj99@194.109.133.133> (permalink) |
| Date | 2012-04-23 10:22 +0000 |
Puzzled wrote on 22 apr 2012 in comp.lang.javascript:
>>> document.getElementById('some_td_id').style.background-image =
>>> foo.src ;
>>
>>Do you want to substract mathematically
>>the value of image from the value of ...style.background?
>
> No, I want to impose the value of image on the background.
Indeed, so with this choice of yours you are indisposed.
I shall explain again:
javascript:
....style.background-image
is incorrect because the '-' is the javascript substraction operator.
In javascript the '-' is to be converted to the capirtaisation of the next
character:
....style.backgroundImage
>>Try:
>>
>>document.getElementById('some_td_id').style.backgroundImage =
>
> Why wouldn't that be a syntax error?
Why wouldn't 1+1=2 be correct?
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Preloading PNGs & assigning as bkgd-image Puzzled <scratching.head@example.com> - 2012-04-21 14:20 -0400
Re: Preloading PNGs & assigning as bkgd-image Stefan Weiss <krewecherl@gmail.com> - 2012-04-21 20:50 +0200
Re: Preloading PNGs & assigning as bkgd-image Puzzled <scratching.head@example.com> - 2012-04-22 06:12 -0400
Re: Preloading PNGs & assigning as bkgd-image Stefan Weiss <krewecherl@gmail.com> - 2012-04-22 20:18 +0200
Re: Preloading PNGs & assigning as bkgd-image "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-21 18:56 +0000
Re: Preloading PNGs & assigning as bkgd-image Puzzled <scratching.head@example.com> - 2012-04-22 07:07 -0400
Re: Preloading PNGs & assigning as bkgd-image "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-23 10:22 +0000
Re: Preloading PNGs & assigning as bkgd-image Stefan Weiss <krewecherl@gmail.com> - 2012-04-23 20:46 +0200
Re: Preloading PNGs & assigning as bkgd-image Puzzled <scratching.head@example.com> - 2012-04-24 08:42 -0400
Re: Preloading PNGs & assigning as bkgd-image SAM <stephanemoriaux.NoAdmin@wanadoo.fr.invalid> - 2012-04-22 00:24 +0200
csiph-web