I'm trying to make a xhtml valid search form using an if/else php statement. I want the searchform to say 'Search...' before you type into it, but as soon as you type, it needs to show what you are typing.
This is the code I have so far:
value=" <?php
if
echo "Search";
else
echo "<?php the_search_query(); ?>";
?>
I want the if statement to be something along the lines of if the search query is blank, however I have no idea how to write this in php.
Any help will be greatly appreciated!