Question
Simple question: How do i set the
WebTopBar so the search defaults to all webs?
Peter said, "Search all webs: Add a web="all,-Trash" to the search form."
so i changed it to
* <form name="quickSearchForm" action="%SCRIPTURLPATH{view}%/%INCLUDINGWEB%/WebSearch">%IF{" '%URLPARAM{"search" encode="entity" scope="topic"}%' = '' " then="<input type=\"text\" class=\"twikiInputField patternFormFieldDefaultColor\" name=\"search\" value=\"%MAKETEXT{"Search"}%\" size=\"14\" onfocus=\"clearDefaultandCSS(this);\" onblur=\"setDefaultText(this);\" />" else="<input type=\"text\" class=\"twikiInputField\" name=\"search\" value=\"%URLPARAM{ "search" encode="entity" scope="topic" web="all,-Trash"}%\" size=\"14\" />"}%</form>
But that didn't work. what am I doing wrong?
Environment
--
GrazianoMisuraca - 25 May 2007
Answer
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.
Put the parameters in hidden formfields:
<form name="quickSearchForm" action="%SCRIPTURLPATH{view}%/%INCLUDINGWEB%/WebSearch">%IF{" '%URLPARAM{"search" encode="entity"}%' = '' " then="<input type=\"text\" class=\"twikiInputField patternFormFieldDefaultColor\" name=\"search\" value=\"%MAKETEXT{"Search"}%\" size=\"14\" onfocus=\"clearDefaultandCSS(this);\" onblur=\"setDefaultText(this);\" />" else="<input type=\"text\" class=\"twikiInputField\" name=\"search\" value=\"%URLPARAM{ "search" encode="entity" }%\" size=\"14\" />"}%<input type="hidden" name="scope" value="all" /><input type="hidden" name="web" value="all" /></form>
--
ArthurClemens - 25 May 2007
Worked, changed it so it's all,-Trash though.
--
GrazianoMisuraca - 28 May 2007
See also
HowToChangeSearchBoxScope,
SearchInWebTopBar.
--
PeterThoeny - 01 Jun 2007