I'm looking for the attribute I need in the input tag to make it so that when a client clicks on the field, or tabs over to it, the value in that tag goes away.

I'm kinda new to wed dev and am teaching my self as I go. The latest thing I have added to the site I have built (see my profile) is this web form (mailto: ) and I want this particular field to show the type of date format i want them to type in, but when they click on, or tab to, the field I want the value to disappear.

Thanks in advance for your help.

David
RedSabre

i believe that would be javascript that you need then. HTML is all static, and so i you shouldnt/wouldnt be able to do somthing interactive like that...i believe...but maybe not..everydays a learning experience.

Thanks for the tip K-T... I'll look into it and post back when I figure it out.

He's right. HTML Is static, it will require javascript. It's real easy though, in the input tag, it would be something like this:

<INPUT TYPE="TEXT" NAME="cool" onFocus="javascript:this.value = '';">

Sweet! Thanks Comatose... is there anything required to be put in the <HEAD> section of the HTML document to make that work? I'll go play around with it now.

Comatose, you're a friggin' genius. It worked right outta the box man! Thanks again.

<INPUT TYPE="TEXT" NAME="cool" onFocus="javascript:this.value = '';">
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.