summaryrefslogtreecommitdiffstats
path: root/system/helpers/html_helper.php
diff options
context:
space:
mode:
Diffstat (limited to 'system/helpers/html_helper.php')
-rwxr-xr-xsystem/helpers/html_helper.php17
1 files changed, 11 insertions, 6 deletions
diff --git a/system/helpers/html_helper.php b/system/helpers/html_helper.php
index c6103ab6f..b64b60650 100755
--- a/system/helpers/html_helper.php
+++ b/system/helpers/html_helper.php
@@ -40,9 +40,10 @@
*/
if ( ! function_exists('heading'))
{
- function heading($data = '', $h = '1')
+ function heading($data = '', $h = '1', $attributes = '')
{
- return "<h".$h.">".$data."</h".$h.">";
+ $attributes = ($attributes != '') ? ' '.$attributes : $attributes;
+ return "<h".$h.$attributes.">".$data."</h".$h.">";
}
}
@@ -123,6 +124,10 @@ if ( ! function_exists('_list'))
}
$attributes = $atts;
}
+ elseif (is_string($attributes) AND strlen($attributes) > 0)
+ {
+ $attributes = ' '. $attributes;
+ }
// Write the opening list tag
$out .= "<".$type.$attributes.">\n";
@@ -258,13 +263,13 @@ if ( ! function_exists('doctype'))
if ( ! is_array($_doctypes))
{
- if (defined('ENVIRONMENT') AND is_file(APPPATH.'config/'.ENVIRONMENT.'/doctypes'.EXT))
+ if (defined('ENVIRONMENT') AND is_file(APPPATH.'config/'.ENVIRONMENT.'/doctypes.php'))
{
- include(APPPATH.'config/'.ENVIRONMENT.'/doctypes'.EXT);
+ include(APPPATH.'config/'.ENVIRONMENT.'/doctypes.php');
}
- elseif (is_file(APPPATH.'config/doctypes'.EXT))
+ elseif (is_file(APPPATH.'config/doctypes.php'))
{
- include(APPPATH.'config/doctypes'.EXT);
+ include(APPPATH.'config/doctypes.php');
}
if ( ! is_array($_doctypes))