i am designing a few pages. the pages have a few main divs and that is how i am inserting the background(with css)
i can render the whole background to the browser but i dont get how to nest divs inside divs with OOP.
any help would be greatly apreciated!
regards.
<?php
class page{
var $leftContent;
var $rightContent;
var $styles = "styles/bglayout.css";
var $title = "Man of Honor";
var $keywords = "Man of Honor, MoH, socom 1, socom 2, socom 3, socom combined assault, socom confrontation, call of duty 4, cod4, clan, psychoraptor, pallaso_loko";
var $buttons = array('Home' => 'index.php', 'Roster' => 'roster.php', 'Code of Conduct' => 'coc.php', 'Members Lounge' => 'Members_lounge.php', 'Register' => 'register.php');
//Set new functions
function SetLeftContent($newleftcontent){
$this->leftContent = $newleftcontent;
}
function SetRightContent($newrightcontent){
$this->rightcontent = $newrightcontent;
}
function SetStyle($newstyle){
$this->style = $newstyle;
}
function SetTitle($newtitle){
$this->title = $newtitle;
}
function SetKeywords($newkeywords){
$this->keywords = $newkeywords;
}
function SetButtons($newbuttons){
$this->buttons = $newbuttons;
}
//Display functions
function DisplayTitle(){
echo "<title> $this->title </title>\n";
}
function DisplayKeywords(){
echo "<meta name=\"keywords\" content=\"$this->keywords\" />\n";
}
function DisplayStyles(){
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"$this->styles\" />\n";
}
function DisplayHeader(){
echo '<div class="page_header">
</div>';
}
function DisplayContentTop(){
echo '<div class="content_top">
</div>';
}
function DisplaySpacer(){
echo '<div class="content_spacer">
</div>';
}
function DisplayContentBottom(){
echo '<div class="content_bottom">
</div>';
}
function DisplayLeftContent(){
echo $this->leftContent;
}
function DisplayRightContent(){
echo $this->rightcontent;
}
function DisplayMenu($buttons){
}
function Display(){
echo "<html>\n<head>\n";
$this->DisplayTitle();
$this->DisplayKeywords();
$this->DisplayStyles();
echo "</head>\n<body>\n";
$this->DisplayHeader();
$this->DisplayContentTop();
$this->DisplaySpacer();
$this->DisplayContentBottom();
$this->DisplayMenu($this->buttons);
$this->DisplayrightContent($this->rightcontent);
echo "</body>\n</html>\n";
}
}
?>