diff options
-rw-r--r-- | it_html.class | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/it_html.class b/it_html.class index 2a93473..0f29bab 100644 --- a/it_html.class +++ b/it_html.class @@ -88,7 +88,7 @@ function it_html($p = array()) 'use_it_state' => false, # If true, generate code needed by state.js (aka 'history iframe') 'srclines' => $GLOBALS['debug_srclines'], # append stackdump to each tag ); - $this->p['notexported'] = trim($p['notexported'] . ',configure,sanitize', ','); + $this->p['notexported'] = trim($p['notexported'] . ',configure,sanitize,comment', ','); # We know these doctypes. If you need something else, supply 'doctype' in p $this->doctypes = array( @@ -415,6 +415,14 @@ function select($tags, $options, $selected = null) return $this->_tag("select", array($tags, $html)); } +/** + * Outputs string as correctly quoted HTML comment + */ +function comment($string) +{ + return "<!--" . it::replace('--' => "--", $string) . "-->"; +} + # internal: strip spans added by debug params function _strip_tags($html) { |