openrat-cms

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit f97c8ccf96954fc078ea6458a27f6aa8116e690f
parent 00dc04b5f811fab2fd9e711274421aae2f2135f5
Author: dankert <devnull@localhost>
Date:   Sun, 22 Mar 2009 21:17:52 +0100

Funktionen zum Rendern von HTML-Tags.

Diffstat:
serviceClasses/Html.class.php | 16+++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/serviceClasses/Html.class.php b/serviceClasses/Html.class.php @@ -126,6 +126,20 @@ class Html - + function open_tag($tagname,$attributes) + { + $text = '<'.$tagname; + foreach( $attributes as $attribute_name=>$attribute_value ) + if ( !empty($attribute_value) ) + $text .= ' '.$attribute_name.'="'.$attribute_value.'"'; + $text .= '>'; + return $text; + } + + + function close_tag($tagname) + { + return '</'.$tagname.'>'; + } } ?> \ No newline at end of file