« March 2010 »
M T W T F S S
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31        

This is hot

Upgrade VIA Epia-Board to current 2.6.28.7
100 times viewed
23.02.2009 18:41
t3blog Update to version 0.8.1 (Security, Bugfixes)
54 times viewed
03.02.2010 14:33
LaTeX Font Selection
24 times viewed
29.01.2010 17:17
linux.bigga.de now with RSS Feed
21 times viewed
25.11.2009 09:36

[blog...]

Currently the posts are filtered by: search
Reset this filter to see all posts.

20.12.2009
20:02

Add Searchbox for Indexed Search to Typo3 Page

I started now to add the Typo3 indexed search to some of my websites. But how to add a searchbox on top of the website? There are several extensions for this, but some simple TypoScript is sufficiant. The following code in my template generates such a box (see on top of this page). The style is done of course by CSS.
temp.searchbox >
temp.searchbox = COA
temp.searchbox {
  20 = TEXT
  # pid of page including index_search plugin
  20.typolink.parameter = 46
  20.typolink.returnLast = url
  20.wrap = <form action="|" method="post"><span>

  30 = TEXT
  30.value = <input name="tx_indexedsearch[sword]" value="Search item..." \
type="text" title="Search the homepage." onfocus="javascript:this.value=''" />

  40 = TEXT
  40.value = <input name="submit" value="Search" type="submit" class="submit" />

  50 = TEXT
  50.value = </span></form>
  wrap = <div class="absearchbox">|</div>
}

page.10.subparts.SEARCHBOX < temp.searchbox

[more]

back

[ 09.03.2010 ]