]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blob - doc/bugs/Impossible_to_resize_text_input_in_search_results.mdwn
da4c79841a737664f30e9368eb5921bfac5a79ea
[git.ikiwiki.info.git] / doc / bugs / Impossible_to_resize_text_input_in_search_results.mdwn
1 While working on the [Tails website](https://tails.boum.org/), I didn't
2 managed to resize the text input on top of the search results.
4 This is problematic with our layout and it might be the same for others.
5 For example, reducing a bit the width of the browser on [this
6 page](https://tails.boum.org/ikiwiki.cgi?P=testing) makes the search
7 results jump at the bottom of the page since the text input is wider
8 (size=65 by default) than the body of the page when side by side with
9 the sidebar.
11 Having CSS selectors to style the elements of this form would solve our
12 problem.
14 Here is a patch:
16     From c4c6c9bf3b296c2db10d6fb9e6421d82f341b1cf Mon Sep 17 00:00:00 2001
17     From: sajolida <sajolida@pimienta.org>
18     Date: Sun, 9 Nov 2014 16:48:33 +0100
19     Subject: [PATCH] Add classes to form in search results
20     
21     This is needed to style it, for example to reduce the width of the text
22     input and prevent layout issues.
23     ---
24      templates/searchquery.tmpl | 4 ++--
25      1 file changed, 2 insertions(+), 2 deletions(-)
26     
27     diff --git a/templates/searchquery.tmpl b/templates/searchquery.tmpl
28     index 15bc78e..6277266 100644
29     --- a/templates/searchquery.tmpl
30     +++ b/templates/searchquery.tmpl
31     @@ -33,8 +33,8 @@ $def{NEXT,$if{$ne{$last,$msize},<INPUT TYPE=submit NAME="&gt;" VALUE="Next">}}
32      
33      <FORM NAME=P METHOD=GET
34      ACTION="$html{$env{CGIURL}}" TARGET="_top">
35     -<div style="text-align:center">
36     -<INPUT NAME=P VALUE="$html{$query}" SIZE=65>
37     +<div class="searchquery" style="text-align:center">
38     +<INPUT class="searchbox" NAME=P VALUE="$html{$query}" SIZE=65>
39      <INPUT TYPE=SUBMIT VALUE="Search">
40      $env{HELPLINK}
41      <hr>
42     --
43     2.1.1