diff options
author | Bharat Mediratta <bharat@menalto.com> | 2011-01-21 00:07:00 -0800 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2011-01-21 00:07:00 -0800 |
commit | 08c41f2976cb49b85ec896b11735edb008d53881 (patch) | |
tree | c0eafa337dea313f806620bd17fbbc775ecf55aa | |
parent | 09a593c832cc768f7e2496273eff4b9b0f77afe0 (diff) |
Add "html_attributes" theme callback to allow modules to inject attributes into
the <html> element, including things like namespaces. Fixes #1615.
-rw-r--r-- | modules/gallery/libraries/Admin_View.php | 1 | ||||
-rw-r--r-- | modules/gallery/libraries/Theme_View.php | 1 | ||||
-rw-r--r-- | themes/admin_wind/views/admin.html.php | 2 | ||||
-rw-r--r-- | themes/wind/views/page.html.php | 2 |
4 files changed, 4 insertions, 2 deletions
diff --git a/modules/gallery/libraries/Admin_View.php b/modules/gallery/libraries/Admin_View.php index 1a633a34..b5d3871e 100644 --- a/modules/gallery/libraries/Admin_View.php +++ b/modules/gallery/libraries/Admin_View.php @@ -86,6 +86,7 @@ class Admin_View_Core extends Gallery_View { case "admin_page_top": case "admin_head": case "body_attributes": + case "html_attributes": $blocks = array(); foreach (module::active() as $module) { $helper_class = "{$module->name}_theme"; diff --git a/modules/gallery/libraries/Theme_View.php b/modules/gallery/libraries/Theme_View.php index 04784ca1..cdc7a7cd 100644 --- a/modules/gallery/libraries/Theme_View.php +++ b/modules/gallery/libraries/Theme_View.php @@ -224,6 +224,7 @@ class Theme_View_Core extends Gallery_View { case "head": case "header_bottom": case "header_top": + case "html_attributes": case "page_bottom": case "page_top": case "photo_blocks": diff --git a/themes/admin_wind/views/admin.html.php b/themes/admin_wind/views/admin.html.php index 54b30c6f..9e011c69 100644 --- a/themes/admin_wind/views/admin.html.php +++ b/themes/admin_wind/views/admin.html.php @@ -1,7 +1,7 @@ <?php defined("SYSPATH") or die("No direct script access.") ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<html xmlns="http://www.w3.org/1999/xhtml" <?= $theme->html_attributes() ?> xml:lang="en" lang="en"> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <? $theme->start_combining("script,css") ?> diff --git a/themes/wind/views/page.html.php b/themes/wind/views/page.html.php index 441866d5..0e5bdf6b 100644 --- a/themes/wind/views/page.html.php +++ b/themes/wind/views/page.html.php @@ -1,7 +1,7 @@ <?php defined("SYSPATH") or die("No direct script access.") ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<html xmlns="http://www.w3.org/1999/xhtml" <?= $theme->html_attributes() ?> xml:lang="en" lang="en"> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <? $theme->start_combining("script,css") ?> |