This do it for ya?

<script>
        function setBackground(obj,mode)
                {
                if (mode == "blur")
                        {obj.style.backgroundImage = "URL('[imagePath]')";}
                else
                        {obj.style.backgroundImage = "";}
                }
</script>
<input type="Text" onblur="setBackground(this,'blur');"
onfocus="setBackground(this,'focus');"
style="background-image:URL('[imagePath]');">

Steve

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Steve Onnis
Sent: Friday, January 23, 2004 2:02 AM
To: CFAussie Mailing List
Subject: [cfaussie] RE: onFocus form


Stuart

Something like this should do you

<script>
        function setBackground(obj,mode)
                {
                if (mode == "blur")
                        {obj.style.backgroundImage = "URL('[imagePath]')";}
                else
                        {obj.style.backgroundImage = "";}
                }
</script>
<input type="Text" onblur="setBackground(this,'blur');"
onfocus="setBackground(this,'focus');"
style="background-image:URL('[imagePath]');">

Regards
Steve Onnis

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Stuart Kidd
Sent: Thursday, 22 January 2004 10:20 PM
To: CFAussie Mailing List
Subject: [cfaussie] onFocus form


If anyone has the Google desktop bar you'll notice that in the textbox
is a Google image and when you click into the textbox the image
disappears, anyone know how to do that?

I remember seeing this on the list and can get that to work no problem
but I'd like it to load an image instead of text.  I can automatically
have an image load through the stylesheet but don't know how to get rid
of it when a mouse clicks into the textbox.

<input type="text" name="email" value="[EMAIL PROTECTED]" size="24"
onFocus="this.value=''">

Thanks,

Saturday




---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MXDU2004 + Macromedia DevCon AsiaPac + Sydney, Australia
http://www.mxdu.com/ + 24-25 February, 2004


---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MXDU2004 + Macromedia DevCon AsiaPac + Sydney, Australia
http://www.mxdu.com/ + 24-25 February, 2004


---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MXDU2004 + Macromedia DevCon AsiaPac + Sydney, Australia
http://www.mxdu.com/ + 24-25 February, 2004

Reply via email to