From c29957e0177c3c654a1ea1feffdba00307449560 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 29 Oct 2009 18:05:58 -0400 Subject: google: Pass the whole wiki url to google, not just the domain, so that search works correctly for wikis that are located in subdirectories of domains. --- templates/googleform.tmpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'templates/googleform.tmpl') diff --git a/templates/googleform.tmpl b/templates/googleform.tmpl index e2d4a1f43..bcf1004a4 100644 --- a/templates/googleform.tmpl +++ b/templates/googleform.tmpl @@ -1,6 +1,6 @@
- +
-- cgit v1.2.3 From b21df5029b94c5680d8a3e5f0c1ed40a660a1594 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sun, 2 May 2010 13:49:56 -0400 Subject: Add placeholder text in search form (in html5 mode only). --- IkiWiki/Plugin/google.pm | 1 + IkiWiki/Plugin/search.pm | 1 + debian/changelog | 1 + doc/bugs/html5_support.mdwn | 3 --- doc/todo/Add_label_to_search_form_input_field.mdwn | 2 ++ templates/googleform.tmpl | 3 ++- templates/searchform.tmpl | 3 ++- 7 files changed, 9 insertions(+), 5 deletions(-) (limited to 'templates/googleform.tmpl') diff --git a/IkiWiki/Plugin/google.pm b/IkiWiki/Plugin/google.pm index 85467fa0b..68cde261c 100644 --- a/IkiWiki/Plugin/google.pm +++ b/IkiWiki/Plugin/google.pm @@ -42,6 +42,7 @@ sub pagetemplate (@) { if (! defined $form) { my $searchform = template("googleform.tmpl", blind_cache => 1); $searchform->param(url => $config{url}); + $searchform->param(html5 => $config{html5}); $form=$searchform->output; } diff --git a/IkiWiki/Plugin/search.pm b/IkiWiki/Plugin/search.pm index be39fdf1e..9e875c79c 100644 --- a/IkiWiki/Plugin/search.pm +++ b/IkiWiki/Plugin/search.pm @@ -58,6 +58,7 @@ sub pagetemplate (@) { if (! defined $form) { my $searchform = template("searchform.tmpl", blind_cache => 1); $searchform->param(searchaction => $config{cgiurl}); + $searchform->param(html5 => $config{html5}); $form=$searchform->output; } diff --git a/debian/changelog b/debian/changelog index 8158429a0..c9fc2e657 100644 --- a/debian/changelog +++ b/debian/changelog @@ -2,6 +2,7 @@ ikiwiki (3.20100502) UNRELEASED; urgency=low * Add parameter to displaytime to specify that it is a pubdate, and in html5 mode, use time tag. + * Add placeholder text in search form (in html5 mode only). -- Joey Hess Sun, 02 May 2010 13:22:50 -0400 diff --git a/doc/bugs/html5_support.mdwn b/doc/bugs/html5_support.mdwn index 386a3094a..5530b29db 100644 --- a/doc/bugs/html5_support.mdwn +++ b/doc/bugs/html5_support.mdwn @@ -64,11 +64,8 @@ HTML5](http://www.w3.org/TR/html5-diff/). > > Other ideas: > -> * Add pubdate attribute to time elements as appropriate. > * Use aside for the sidebar? Or for the [[templates/note]] template? > * Use nav for the actionbar -> * Use placeholder in the search box. Allows closing -> [[this_todo|Add_label_to_search_form_input_field]] > * Use details tag instead of the javascript in the toggle plugin. > (Need to wait on browser support probably.) > diff --git a/doc/todo/Add_label_to_search_form_input_field.mdwn b/doc/todo/Add_label_to_search_form_input_field.mdwn index 281ab48e2..514108fba 100644 --- a/doc/todo/Add_label_to_search_form_input_field.mdwn +++ b/doc/todo/Add_label_to_search_form_input_field.mdwn @@ -51,4 +51,6 @@ The patch below adds a label for the field to improve usability: > element. already works in eg, chromium. However, ikiwiki does not use > html5 yet. --[[Joey]] +>> [[Done]], placeholder added, in html5 mode only. + [[!tag wishlist bugs/html5_support]] diff --git a/templates/googleform.tmpl b/templates/googleform.tmpl index bcf1004a4..f39b46540 100644 --- a/templates/googleform.tmpl +++ b/templates/googleform.tmpl @@ -1,6 +1,7 @@
- + placeholder="search" />
diff --git a/templates/searchform.tmpl b/templates/searchform.tmpl index afae2ebf5..cb65d124c 100644 --- a/templates/searchform.tmpl +++ b/templates/searchform.tmpl @@ -1,5 +1,6 @@
- +placeholder="search" />
-- cgit v1.2.3 From f52f395437a946478da2a126015c05e3e0afdc1f Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 5 May 2010 21:08:41 -0400 Subject: consistently drop NAME= in templates also add template syntax smoke test --- doc/ikiwiki/directive/template.mdwn | 8 ++--- doc/templates.mdwn | 4 +-- doc/templates/gitbranch.mdwn | 2 +- doc/templates/note.mdwn | 2 +- doc/templates/plugin.mdwn | 2 +- doc/templates/popup.mdwn | 2 +- templates/aggregatepost.tmpl | 18 +++++------ templates/archivepage.tmpl | 6 ++-- templates/atomitem.tmpl | 24 +++++++------- templates/atompage.tmpl | 10 +++--- templates/blogpost.tmpl | 8 ++--- templates/change.tmpl | 18 +++++------ templates/comment.tmpl | 30 ++++++++--------- templates/commentmoderation.tmpl | 4 +-- templates/editcomment.tmpl | 12 +++---- templates/editpage.tmpl | 12 +++---- templates/feedlink.tmpl | 8 ++--- templates/googleform.tmpl | 1 + templates/inlinepage.tmpl | 18 +++++------ templates/microblog.tmpl | 4 +-- templates/page.tmpl | 64 ++++++++++++++++++------------------- templates/pocreatepage.tmpl | 4 +-- templates/renamesummary.tmpl | 4 +-- templates/rssitem.tmpl | 14 ++++---- templates/titlepage.tmpl | 2 +- 25 files changed, 141 insertions(+), 140 deletions(-) (limited to 'templates/googleform.tmpl') diff --git a/doc/ikiwiki/directive/template.mdwn b/doc/ikiwiki/directive/template.mdwn index 052ca7873..6c50fa32e 100644 --- a/doc/ikiwiki/directive/template.mdwn +++ b/doc/ikiwiki/directive/template.mdwn @@ -53,21 +53,21 @@ few things: * To insert the raw value of a variable, with wiki markup not yet converted to html, use ``. * To make a block of text conditional on a variable being set use - `text`. + `text`. * To use one block of text if a variable is set and a second if it's not, - use `textother text` + use `textother text` Here's a sample template: Name: \[[]]
Age:
- + Favorite color:
No favorite color.
- +
diff --git a/doc/templates.mdwn b/doc/templates.mdwn index 2444cf14d..8f6561fcf 100644 --- a/doc/templates.mdwn +++ b/doc/templates.mdwn @@ -12,9 +12,9 @@ easy to learn. All you really need to know to modify templates is this: * To insert the value of a template variable, use ``. * To make a block of text conditional on a variable being set use - `text`. + `text`. * To use one block of text if a variable is set and a second if it's not, - use `textother text` + use `textother text` [[!if test="enabled(template)" then=""" ## template pages diff --git a/doc/templates/gitbranch.mdwn b/doc/templates/gitbranch.mdwn index fcce925d9..962420940 100644 --- a/doc/templates/gitbranch.mdwn +++ b/doc/templates/gitbranch.mdwn @@ -3,7 +3,7 @@ Available in a [[!taglink /git]] repository.
Branch:
Author:
- + This template is used to create an infobox for a git branch. It uses these parameters: diff --git a/doc/templates/note.mdwn b/doc/templates/note.mdwn index 4cc323c0e..9ef5ad942 100644 --- a/doc/templates/note.mdwn +++ b/doc/templates/note.mdwn @@ -1,7 +1,7 @@
- + Use this template to insert a note into a page. The note will be styled to float to the right of other text on the page. This template has one parameter: diff --git a/doc/templates/plugin.mdwn b/doc/templates/plugin.mdwn index c1d1974d6..322c49445 100644 --- a/doc/templates/plugin.mdwn +++ b/doc/templates/plugin.mdwn @@ -8,7 +8,7 @@ Currently enabled: [[!if test="enabled()" then="yes" else="no"]]< [[!if test="sourcepage(plugins/contrib/*)" then="""[[!meta title=" (third party plugin)"]]"""]] [[!tag plugins/type/core]] - + This template is used to create an infobox for an ikiwiki plugin. It uses these parameters:
    diff --git a/doc/templates/popup.mdwn b/doc/templates/popup.mdwn index b355daa2e..92455eb21 100644 --- a/doc/templates/popup.mdwn +++ b/doc/templates/popup.mdwn @@ -1,4 +1,4 @@ - + Use this template to create a popup window that is displayed when the mouse is over part of the page. This template has two parameters:
      diff --git a/templates/aggregatepost.tmpl b/templates/aggregatepost.tmpl index 8b8936733..4e89efe32 100644 --- a/templates/aggregatepost.tmpl +++ b/templates/aggregatepost.tmpl @@ -1,15 +1,15 @@ - + [[!tag ]] - -[[!meta title=""]] + +[[!meta title=""]] - -[[!meta permalink=""]] + +[[!meta permalink=""]] - -[[!meta copyright=""]] + +[[!meta copyright=""]] -[[!meta author=""]] -[[!meta authorurl=""]] +[[!meta author=""]] +[[!meta authorurl=""]] diff --git a/templates/archivepage.tmpl b/templates/archivepage.tmpl index 28800e763..93bdd9ce0 100644 --- a/templates/archivepage.tmpl +++ b/templates/archivepage.tmpl @@ -1,14 +1,14 @@

      - +

      Posted - + by - + diff --git a/templates/atomitem.tmpl b/templates/atomitem.tmpl index 87cbee9e0..4ed17bc62 100644 --- a/templates/atomitem.tmpl +++ b/templates/atomitem.tmpl @@ -1,17 +1,17 @@ <TMPL_VAR TITLE> - + - + - + - + @@ -19,30 +19,30 @@ - + - - + + - + - - " type="text/html" /> + + - - " type="application/atom+xml" /> + + diff --git a/templates/atompage.tmpl b/templates/atompage.tmpl index fc0088ae8..e82b59827 100644 --- a/templates/atompage.tmpl +++ b/templates/atompage.tmpl @@ -5,15 +5,15 @@ - + - + - + @@ -21,13 +21,13 @@ - + - + diff --git a/templates/blogpost.tmpl b/templates/blogpost.tmpl index 7eeede603..5a31e3f8a 100644 --- a/templates/blogpost.tmpl +++ b/templates/blogpost.tmpl @@ -1,10 +1,10 @@

      - -RSS + +RSS - -Atom + +Atom diff --git a/templates/change.tmpl b/templates/change.tmpl index 5f277a0fb..671b9e483 100644 --- a/templates/change.tmpl +++ b/templates/change.tmpl @@ -2,15 +2,15 @@ [[!meta authorurl=""""""]] -[[!meta title="""change to on """]] +[[!meta title="""change to on """]] [[!meta permalink=""]]
      - - -
      + + +
      - +
      -
      +
       
      diff --git a/templates/comment.tmpl b/templates/comment.tmpl index 39cba0ff9..fa90e6d26 100644 --- a/templates/comment.tmpl +++ b/templates/comment.tmpl @@ -1,5 +1,5 @@ -
      -
      +
      +
      @@ -15,40 +15,40 @@
      Comment by - - + + - + - - + + - + - - + + - - + + - +
      - +