I am trying to learn to write modules. I have a good start, but I'm trying to add a search box. I studied the search block and search module, but still can't figure this thing out.
This is my code snippet:
Code
$content = "<form method=\"post\" action=\"modules.php?op=modload&name=testmodule&file=index&mode=search&query=\">";
$content .= "<center><input type=\"text\" name=\"query\" size=\"14\">";
$content .= '<input type="submit" value="Search">';
$content .= '</center>';
$content .= '</form>';
echo $content;
$content .= "<center><input type=\"text\" name=\"query\" size=\"14\">";
$content .= '<input type="submit" value="Search">';
$content .= '</center>';
$content .= '</form>';
echo $content;
What I want is the search term to appear at the end of the URL:
modules.php?op=modload&name=testmodule&file=index&mode=search&query=
line such as:
modules.php?op=modload&name=testmodule&file=index&mode=search&query=dog
Right now when I click on the search button, the page goes to modules.php?op=modload&name=testmodule&file=index&mode=search&query=
I can't get it to append the search term to the end of that line.
Can anyone help me out on this?
Thanks,
Grant
--
Retail Retreat
http://www.retailretreat.com
