Wrox Home  
Search P2P Archive for: Go

  Return to Index  

javascript thread: professional JavaScript


Message #1 by "Phil Perks" <philp@w...> on Thu, 10 Aug 2000 21:16:55
You have to call javascript function e.g:

> <form name=TheForm>
> <input type="button" value="Change Image" onClick="javascript:change()" >
> <input type="button" value="Change Image2" onClick="javascript:change2()"
>
> </form>

cheers,


----- Original Message -----
From: "Phil Perks" <philp@w...>
To: "javascript" <javascript@p...>
Sent: Thursday, August 10, 2000 9:16 PM
Subject: [javascript] professional JavaScript


> -----Original Message-----
> From: erez levi [mailto:levierez@h...]
> Sent: 10 August 2000 20:36
> To: support@w...
> Subject:
>
> Book title: professional JavaScript
> ISBN:     1-861002-70-x    or  9 781861 002709 (I am not sure what the
> number
> is)
>
> Hi my name is Erez. I am trying to resize an image, and below is an
> example:
> <html>
> <head>
> </head>
> <body>
> <img name= "e" src="image/WINLOGO.GIF">
> <br>
> <form name=TheForm>
> <input type="button" value="Change Image" onClick=change() >
> <input type="button" value="Change Image2" onClick=change2() >
> </form>
> <script language="JavaScript">
> function change ()
> {
> document.e.width /= 2
> document.e.lenght /= 2
> }
> function change2 ()
> {
> document.e.width *= 2
> document.e.lenght *= 2
> }
> </script>
>
> </body>
> </html>
>
> It works just fine in explorer but it doesn't work in netscape, do you
> have
> an idea
> why? and how could i get over it?
> Thank you very much for you time, Erez
>
minh@m...
>
>


  Return to Index