oldzy — 2010-06-22T20:59:16-04:00 — #1
I have a basic search box that I want filled with light gray text that says <enter search query> or similar, and I want it to disappear when the box is clicked on. I also want the '<enter search query>' to reappear when the page is reloaded.
Any tips, URLs, etc. with info are appreciated.
oldzy — 2010-06-23T02:10:03-04:00 — #2
$query =~ s/ \<enter query\>//g;
oldzy — 2010-06-23T01:49:44-04:00 — #3
hmmm, another prob though. If someone simply clicks on the search button, the query ends up being <enter query>.
oldzy — 2010-06-23T01:48:11-04:00 — #4
Figured it out. Pretty simple.
<input type="text" name="query" size="16" maxlength="40" value=" <enter query>" class="search_box" onFocus=this.value=''>