openside("Search...");
echo "<form name='searchform' method='get' action='".BASEDIR."search.php'>
<input type='textbox' value='' name='stext' class='searchbox' width='90px'></td><td class='panelsearch'>
<input type='image' name='search' src='".THEME."images/go.png'> </td></tr>
</form>";
closeside();
.panelsearch {
text-align: left;
width: 20px;
background: url('images/search.png') right center no-repeat;
}
openside("Search News");
echo "<form id='searchform' name='searchform' method='get' action='".BASEDIR."search.php'>\n";
echo "<input type='text' name='stext' value='".urldecode($_GET['stext'])."' class='textbox' style='width:150px' />\n";
echo "<label><input type='hidden' name='stype' value='news'".($_GET['stype'] == "news" ? " checked='checked'" : "")." onclick=\"display(this.value)\" /></label><br>\n";
echo "<input type='submit' name='search' value='Search' class='button' /> <input type='reset' name='reset' value='Reset' class='button' />\n</form>\n";
closeside();
?>
openside("Search Forums");
echo "<form id='searchform' name='searchform' method='get' action='".BASEDIR."search.php'>\n";
echo "<input type='text' name='stext' value='".urldecode($_GET['stext'])."' class='textbox' style='width:150px' />\n";
echo "<br><label><input type='radio' name='stype' value='news'".($_GET['stype'] == "news" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />News</label>\n";
echo "<br><label><input type='radio' name='stype' value='articles'".($_GET['stype'] == "articles" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />Articles</label>\n";
echo "<br><label><input type='radio' name='stype' value='custompages'".($_GET['stype'] == "custompages" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />Custom Pages</label>\n";
echo "<br><label><input type='radio' name='stype' value='downloads'".($_GET['stype'] == "downloads" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />Downloads</label>\n";
echo "<br><label><input type='radio' name='stype' value='faqs'".($_GET['stype'] == "faqs" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />FAQs</label>\n";
echo "<br><label><input type='radio' name='stype' value='members'".($_GET['stype'] == "members" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />Members</label>\n";
echo "<br><label><input type='radio' name='stype' value='photos'".($_GET['stype'] == "photos" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />Photos</label>\n";
echo "<br><label><input type='radio' name='stype' value='weblinks'".($_GET['stype'] == "weblinks" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />Web Links</label>\n";
echo "<br><label><input type='radio' name='stype' value='all'".($_GET['stype'] == "all" ? " checked='checked'" : "")." onclick=\"display(this.value)\" />Entire Site</label>\n";
echo "<input type='submit' name='search' value='Search' class='button' /> <input type='reset' name='reset' value='Reset' class='button' />\n</form>\n";
closeside();
?>
Notice: Undefined index: stext in /home/content/m/u/l/mulinks/html/administration/panel_editor.php(128) : eval()'d code on line 3
Notice: Undefined index: stype in /home/content/m/u/l/mulinks/html/administration/panel_editor.php(128) : eval()'d code on line 4
openside("Search News");
echo "<form id='searchform' name='searchform' method='get' action='".BASEDIR."search.php'>\n";
echo "<input type='text' name='stext' value='".urldecode($_GET['stext'])."' class='textbox' style='width:150px' />\n";
echo "<label><input type='hidden' name='stype' value='news'".($_GET['stype'] == "news" ? " checked='checked'" : "")." onclick=\"display(this.value)\" /></label><br>\n";
echo "<input type='submit' name='search' value='Search' class='button' /> <input type='reset' name='reset' value='Reset' class='button' />\n</form>\n";
closeside();
?>
openside("Search News");
if(isset($_GET['stext']) { $stext = $_GET['stext']; } else { $stext = "";}
if(isset($_GET['stype']) { $stext = $_GET['stype']; } else { $stype = "";}
echo "<form id='searchform' name='searchform' method='get' action='".BASEDIR."search.php'>\n";
echo "<input type='text' name='stext' value='".urldecode($stext)."' class='textbox' style='width:150px' />\n";
echo "<label><input type='hidden' name='stype' value='news'".($stype == "news" ? " checked='checked'" : "")." onclick=\"display(this.value)\" /></label><br>\n";
echo "<input type='submit' name='search' value='Search' class='button' /> <input type='reset' name='reset' value='Reset' class='button' />\n</form>\n";
closeside();
?>
Quote
iloveu00 wrote:
Thank you, i tried the code on new panel and got this error:Code Download sourceNotice: Undefined index: stext in /home/content/m/u/l/mulinks/html/administration/panel_editor.php(128) : eval()'d code on line 3
Notice: Undefined index: stype in /home/content/m/u/l/mulinks/html/administration/panel_editor.php(128) : eval()'d code on line 4
The code i tried is as followed:
can you fixed it for me ?
Quote
Jeepers1993 wrote:
Try this:openside("Search News");
if(isset($_GET['stext']) { $stext = $_GET['stext']; } else { $stext = "";}
if(isset($_GET['stype']) { $stext = $_GET['stype']; } else { $stype = "";}
echo "<form id='searchform' name='searchform' method='get' action='".BASEDIR."search.php'>\n";
echo "<input type='text' name='stext' value='".urldecode($stext)."' class='textbox' style='width:150px' />\n";
echo "<label><input type='hidden' name='stype' value='news'".($stype == "news" ? " checked='checked'" : "")." onclick=\"display(this.value)\" /></label><br>\n";
echo "<input type='submit' name='search' value='Search' class='button' /> <input type='reset' name='reset' value='Reset' class='button' />\n</form>\n";
closeside();
?>
Quote
bikerbones wrote:
That panel rafnal gave you will automatically search the forums.
Or you could try my search panel.
This panel will search the forums by default or you can select to search the entire site.
Quote
At the end of your search settings in the admin panel as the default search locations, set the search news.
if (!isset($_GET['stext'])) { $_GET['stext'] = ""; }
if (!isset($_GET['stype'])) { $_GET['stype'] = ""; }
echo "<center><form id='searchform' name='searchform' method='get' action='".BASEDIR."search.php'>\n";
echo "<input type='text' name='stext' value='".urldecode($_GET['stext'])."' class='textbox' style='width:150px' />\n";
echo "<input type='hidden' name='stype' value='downloads'".($_GET['stype'] == "downloads" ? " checked='checked'" : "")." onclick=\"display(this.value)\" /><br />\n";
echo "<input type='submit' name='search' value='Search' class='button' /> <input type='reset' name='reset' value='Reset' class='button' />\n</form>\n</center>";
if (!isset($_GET['stext'])) { $_GET['stext'] = ""; }
if (!isset($_GET['stype'])) { $_GET['stype'] = ""; }
openside("Search");
echo "<center><form id='searchform' name='searchform' method='get' action='".BASEDIR."search.php'>\n";
echo "<input type='text' name='stext' value='".urldecode($_GET['stext'])."' class='textbox' style='width:150px' />\n";
echo "<input type='hidden' name='stype' value='downloads'".($_GET['stype'] == "downloads" ? " checked='checked'" : "")." onclick=\"display(this.value)\" /><br />\n";
echo "<input type='submit' name='search' value='Search' class='button' /> <input type='reset' name='reset' value='Reset' class='button' />\n</form>\n</center>";
closeside();
Category Forum
System Administration - 8Labels
None yet
Statistics
5 participants
Notifications
You are not receiving notifications from this thread.
Related Questions