Re: <img> width height
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.javascript archive

Re: <img> width height

From: News <warren@no_S_P_A_M_wyght.com>
Date: Sat Apr 22 2006 - 22:47:42 CEST

ASM wrote:
> News a écrit :
>>
>> What does this mean??
>>
>>> var myWidth= myImage.style&&myImage.style.width?
>>> myImage.style.width : myImage.width; //attempt to capture width of
>>> <img>
>>
>> At first I thought it was a triune if true this else that type
>> statement but I don't have a clue what it is.
>
> yes it was (would have to be).
>
> if myImage has style and myImage has style width,
> miWidth is myImage.style.width
> else
> miWidth is myImage width
>
> because perhaps your image has no style (or no width or height style)
> ?
> in fact the error was much more stupid
> (all as I've done in my code myWidth=myImage.style.height ! !)

I hope one day I will be able to avoid stupid mistakes or at the very least
find them before I air them to the WORLD ;-)

-- 
Totus possum, totum Deum.
Totus ero, totum meum.
WSW
Received on Mon May 1 05:15:40 2006