Vanilla 1.1.5 is a product of Lussumo. More Information: Documentation, Community Support.
Help keep Vanilla free:1 to 12 of 12
<?php
class Head extends Control {
var $Scripts; // Script collection
var $StyleSheets; // Stylesheet collection
var $Strings; // String collection
var $BodyId; // identifier assigned to the body tag
var $Meta; // An associative array of meta tags/content to be added to the head.
function AddScript($ScriptLocation, $ScriptRoot = '~') {
if ($ScriptRoot == '~') $ScriptRoot = $this->Context->Configuration['WEB_ROOT'];
$ScriptPath = $ScriptLocation;
if ($ScriptRoot != '') $ScriptPath = ConcatenatePath($ScriptRoot, $ScriptLocation);
if (!in_array($ScriptPath, $this->Scripts)) $this->Scripts[] = $ScriptPath;
}
function AddStyleSheet($StyleSheetLocation, $Media = '', $Position = '100', $StyleRoot = '~') {
if ($StyleRoot == '~') $StyleRoot = $this->Context->Configuration['WEB_ROOT'];
$StylePath = $StyleSheetLocation;
if ($StylePath != '') $StylePath = ConcatenatePath($StyleRoot, $StyleSheetLocation);
$this->InsertItemAt($this->StyleSheets,
array('Sheet' => $StylePath, 'Media' => $Media),
$Position);
}
function AddString($String) {
$this->Strings[] = $String;
}
function Clear() {
$this->ClearStrings();
$this->ClearStyleSheets();
$this->ClearScripts();
$this->Meta = array();
}
function ClearStrings() {
$this->Strings = array();
}
function ClearStyleSheets() {
$this->StyleSheets = array();
}
function ClearScripts() {
$this->Scripts = array();
}
function Head(&$Context) {
$this->Name = 'Head';
$this->BodyId = '';
$this->Control($Context);
$this->Clear();
}
function Render() {
// First sort the stylesheets by key
ksort($this->StyleSheets);
$this->CallDelegate('PreRender');
include(ThemeFilePath($this->Context->Configuration, 'head.php'));
$this->CallDelegate('PostRender');
}
}
?>I'm looking into some of the other messages...
function Database(&$Context) {
$this->Name = 'Database';
$this->Connection = 0;
$Context->ErrorManager->AddError($Context, $this->Name, 'Constructor', 'You can not generate a database object with the database interface. You must use an implementation of the interface like the MySQL implementation.');
} function User(&$Context) {
$this->Context = &$Context;
$this->Clear();
} function Search() {
$this->clear();
}
function MySql(&$Context) {
$this->Name = 'MySQL';
$this->Context = &$Context;
$this->Conection = 0;
$this->FarmConnection = 0;
} function Validator(&$Context) {
$this->Context = &$Context;
$this->Clear();
}error_reporting(7);1 to 12 of 12