[textpattern commit] r2939 - in development/4.0: . .cache textpattern/publish

0 views
Skip to first unread message

codesite...@google.com

unread,
Jul 18, 2008, 11:17:11 AM7/18/08
to txp...@googlegroups.com
Author: r.wetzlmayr
Date: Fri Jul 18 08:16:12 2008
New Revision: 2939

Added:
development/4.0/.cache/
Modified:
development/4.0/HISTORY.txt
development/4.0/textpattern/publish/taghandlers.php

Log:
txp:search_input: new attribute 'html_id'

Modified: development/4.0/HISTORY.txt
==============================================================================
--- development/4.0/HISTORY.txt (original)
+++ development/4.0/HISTORY.txt Fri Jul 18 08:16:12 2008
@@ -6,6 +6,7 @@
* Changed tags: Container and form capabilities/improvements for
<txp:section_list />, <txp:category_list />, <txp:article />,
<txp:article_custom />, <txp:recent_comments />,
<txp:file_download_list />
* Changed tag: <txp:recent_comment /> allows new attribute 'offset'
+* Changed tag: <txp:search_input /> allows new attribute 'html_id' to
determine the form's id.
* Changed tag: <txp:if_article_id /> defaults to the current article's id.
* Changed tags: <txp:article /> and <txp:article_custom /> allow new attributes 'wraptag', 'break'
* Changed tags: <txp:category /> and <txp:section /> apply the 'class'
attribute to the <A> element when wraptag is empty.

Modified: development/4.0/textpattern/publish/taghandlers.php
==============================================================================
--- development/4.0/textpattern/publish/taghandlers.php (original)
+++ development/4.0/textpattern/publish/taghandlers.php Fri Jul 18
08:16:12 2008
@@ -1085,6 +1085,7 @@
'form' => 'search_input',
'wraptag' => 'p',
'size' => '15',
+ 'html_id' => '',
'label' => gTxt('search'),
'button' => '',
'section' => '',
@@ -1098,23 +1099,24 @@
}

$sub = (!empty($button)) ? '<input type="submit" value="'.$button.'" />' : '';
+ $id = (!empty($html_id)) ? ' id="'.$html_id.'"' : '';
$out = fInput('text','q',$q,'','','',$size);
$out = (!empty($label)) ? $label.br.$out.$sub : $out.$sub;
$out = ($wraptag) ? tag($out,$wraptag) : $out;

if (!$section) {
- return '<form method="get" action="'.hu.'">'.
+ return '<form method="get" action="'.hu.'"'.$id.'>'.
n.$out.
n.'</form>';
}

if ($permlink_mode != 'messy') {
- return '<form method="get" action="'.pagelinkurl(array('s' => $section)).'">'.
+ return '<form method="get" action="'.pagelinkurl(array('s' => $section)).'"'.$id.'">'.
n.$out.
n.'</form>';
}

- return '<form method="get" action="'.hu.'">'.
+ return '<form method="get" action="'.hu.'"'.$id.'">'.
n.hInput('s', $section).
n.$out.
n.'</form>';

Reply all
Reply to author
Forward
0 new messages