showBody() -- revisit to add @id and @class to <body>

showContentBlock()
showContent()

added endHTML() to class HTMLOutputter
This commit is contained in:
sarven 2009-01-14 17:26:23 +00:00
parent efe9d28efa
commit f8b7589324
2 changed files with 21 additions and 18 deletions

View File

@ -172,11 +172,13 @@ class Action extends HTMLOutputter // lawsuit
function showBody() function showBody()
{ {
// output body $this->elementStart('body');
// output wrap element $this->elementStart('wrap');
$this->showHeader(); $this->showHeader();
$this->showCore(); $this->showCore();
$this->showFooter(); $this->showFooter();
$this->elementEnd('wrap');
$this->elementEnd('body');
} }
function showHeader() function showHeader()
@ -260,11 +262,11 @@ class Action extends HTMLOutputter // lawsuit
function showCore() function showCore()
{ {
// start core div $this->elementStart('div' array('class' => 'core'));
$this->showLocalNav(); $this->showLocalNav();
$this->showContentBlock(); $this->showContentBlock();
$this->showAside(); $this->showAside();
// end core div $this->elementEnd('div');
} }
// SHOULD overload (perhaps this should be a MUST because sometimes it is not used) // SHOULD overload (perhaps this should be a MUST because sometimes it is not used)
@ -290,8 +292,7 @@ class Action extends HTMLOutputter // lawsuit
function showContentBlock() function showContentBlock()
{ {
$this->elementStart('div', array('id' => 'content', $this->elementStart('div', array('id' => 'content'));
(is_null("basic single content page e.g., about")) ? null : 'class' => 'hentry'));
$this->showPageTitle(); $this->showPageTitle();
$this->showPageNotice(); $this->showPageNotice();
$this->showContent(); $this->showContent();
@ -319,8 +320,7 @@ class Action extends HTMLOutputter // lawsuit
function showContent() function showContent()
{ {
// show the actual content (forms, lists, whatever) // show the actual content (forms, lists, whatever)
$this->elementStart('div', array('id' => 'content_inner', $this->elementStart('div', array('id' => 'content_inner'));
(is_null("basic single content page e.g., about")) ? null : 'class' => 'entry-content'));
$this->elementEnd('div'); $this->elementEnd('div');
} }
@ -556,16 +556,6 @@ class Action extends HTMLOutputter // lawsuit
$this->elementStart('div', array('id' => 'content')); $this->elementStart('div', array('id' => 'content'));
} }
function common_show_footer()
{
global $xw, $config;
$this->elementEnd('div'); // content div
common_foot_menu();
$this->elementEnd('div');
$this->elementEnd('body');
$this->elementEnd('html');
common_end_xml();
}
// Added @id to li for some control. We might want to move this to htmloutputter.php // Added @id to li for some control. We might want to move this to htmloutputter.php
function common_menu_item($id=null, $url, $text, $title=null, $is_selected=false) function common_menu_item($id=null, $url, $text, $title=null, $is_selected=false)

View File

@ -122,6 +122,19 @@ class HTMLOutputter extends XMLOutputter
'lang' => $language)); 'lang' => $language));
} }
/**
* Ends an HTML document
*
* @return void
*/
function endHTML()
{
$this->elementEnd('html');
$this->endXML();
}
/** /**
* Output an HTML text input element * Output an HTML text input element
* *