Mercurial > hg > fapweb
changeset 746:8fe56276fa4f
Add new helper functions.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Thu, 20 Nov 2014 07:56:18 +0200 |
parents | 7ac6d1fdc078 |
children | 330e6d79c5dc |
files | msite.inc.php |
diffstat | 1 files changed, 18 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/msite.inc.php Thu Nov 20 07:55:57 2014 +0200 +++ b/msite.inc.php Thu Nov 20 07:56:18 2014 +0200 @@ -379,6 +379,24 @@ } +function stGetEditFormTextInput($mode, $title, $size, $len, $name, $id, $prefix, $value, $extra = "") +{ + return + "<div class=\"editControl\"><span class=\"editControlTitle\">".chentities($title)."</span>". + ($mode ? stGetFormTextInput($size, $len, $name, $id, $prefix, $value, $extra) : chentities($value)). + "</div>"; +} + + +function stGetEditFormTextArea($mode, $title, $rows, $cols, $name, $id, $prefix, $value, $extra = "") +{ + return + "<div class=\"editControl\"><span class=\"editControlTitle\">".chentities($title)."</span>". + stGetFormTextArea($rows, $cols, $name, $id, $prefix, $value, ($mode ? "" : " disabled=\"disabled\" ").$extra). + "</div>"; +} + + function stConvSwitchMode(&$str, &$mode, $newMode) { if ($newMode != $mode)