Suchformular auf jede Seite einbinden
Armin Bartsch, Mittwoch, 24. Juni 2009
Eine einfache Möglichkeit um auf jeder Seite ein Suchformlar einzubinden
TypoScript

lib.menue_sub.10 {
10 {
# Gesamter Form Wrap
outerWrap.cObject {
10 {
wrap = <div id="indexedsearchbox"><form action="|" method="post" ><fieldset><legend>Suche</legend>
}
20 {
value = | </fieldset></form></div>
}
}
value (
<input name="tx_indexedsearch[sword]" value="" class="searchbox-sword" type="text" />
<input type="hidden" name="tx_indexedsearch[sections]" value="0" />
<input name="tx_indexedsearch[submit_button]" value="Search" type="hidden" />
<input type="submit" value="Los" class="submit">
)
}
}
CSS

#indexedsearchbox input { /* Alle Labels UND Formularelemente auswählen */
display: block;
float: left;
width: 150px; /* Breite.*/
}
#indexedsearchbox form br { /* Alle Zeilenumbrüche in Formularen auswählen */
clear: left; /* das floating der labels und inputs aufheben */
}
#indexedsearchbox .submit { /* den Submit-Button */
float: none;
padding-left:10px;
width: 40px;
}