summaryrefslogtreecommitdiff
path: root/inc
diff options
context:
space:
mode:
authorAdrian Lang <lang@cosmocode.de>2009-11-26 13:14:28 +0100
committerAdrian Lang <lang@cosmocode.de>2010-01-19 16:43:47 +0100
commit45d0580848a1c48ed59ed416949c0efb4cf790f8 (patch)
tree5b3fff472f49f5fb79d341ededdecafa6a4fe05b /inc
parentbe615a48b77032ed713b970521ed46503be853e7 (diff)
downloadrpg-45d0580848a1c48ed59ed416949c0efb4cf790f8.tar.gz
rpg-45d0580848a1c48ed59ed416949c0efb4cf790f8.tar.bz2
Add target-specific class to section edit button
darcs-hash:20091126121428-e4919-8c21d358a76148a9319bf223d0fa1baba8c92656.gz
Diffstat (limited to 'inc')
-rw-r--r--inc/html.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/inc/html.php b/inc/html.php
index dda797f9e..7f061ffbd 100644
--- a/inc/html.php
+++ b/inc/html.php
@@ -104,7 +104,7 @@ function html_secedit_button($matches){
'lines' => $section,
'edittarget' => $edittarget,
'rev' => $INFO['lastmod']),
- 'post', $name);
+ 'post', $name, 'editbutton_' . $edittarget);
$secedit .= '</div>';
return $secedit;
}
@@ -149,7 +149,7 @@ function html_topbtn(){
*
* @author Andreas Gohr <andi@splitbrain.org>
*/
-function html_btn($name,$id,$akey,$params,$method='get',$tooltip=''){
+function html_btn($name,$id,$akey,$params,$method='get',$tooltip='', $class = ''){
global $conf;
global $lang;
@@ -187,7 +187,9 @@ function html_btn($name,$id,$akey,$params,$method='get',$tooltip=''){
$tip = htmlspecialchars($label);
}
- $ret .= '<input type="submit" value="'.htmlspecialchars($label).'" class="button" ';
+ $class .= ' button';
+
+ $ret .= '<input type="submit" value="'.hsc($label).'" class="' . hsc($class) . '" ';
if($akey){
$tip .= ' ['.strtoupper($akey).']';
$ret .= 'accesskey="'.$akey.'" ';