PRADO Component Framework for PHP 5
  • Home
  • About
  • Testimonials
  • Demos
  • Download
  • Documentation
  • Forum
  • Development
  • Tutorials
  • Class Docs
  • API Manual
  • Wiki

Packages

  • None
  • System
    • Caching
    • Collections
    • Data
      • ActiveRecord
        • Relations
        • Scaffold
          • InputBuilder
      • Commom
        • Sqlite
      • Common
        • Mssql
        • Mysql
        • Oracle
        • Pgsql
        • Sqlite
      • DataGateway
      • SqlMap
        • Configuration
        • Statements
    • Exceptions
    • I18N
    • IO
    • Security
    • Util
    • Web
      • Javascripts
      • Services
      • UI
        • ActiveControls
        • WebControls
    • Xml
  • Wsat
    • pages
  • Overview
  • Package
  • Class
  • Tree
  • Deprecated
  • Todo

Class THead

THead class

THead displays a head element on a page. It displays the content enclosed in its body and the page title set by the setTitle Title property. In addition, stylesheets and JavaScripts registered via TClientScriptManager::registerStyleSheet(), TClientScriptManager::registerStyleSheetFile() TClientScriptManager::registerHeadJavaScript, and TClientScriptManager::registerHeadJavaScriptFile will also be displayed in the head. THead also manages and displays meta tags through its getMetaTags MetaTags property. You can add a meta object to the collection in code dynamically, or add it in template using the following syntax,

<com:THead>
  <com:TMetaTag HttpEquiv="Pragma" Content="no-cache" />
  <com:TMetaTag Name="keywords" Content="Prado" />
</com:THead>

Note, TPage has a property TPage::getHead Head that refers to the THead control currently on the page. A page can have at most one THead control. Although not required, it is recommended to place a THead on your page. Without a THead on the page, stylesheets and javascripts in the current page theme will not be rendered.

TComponent
Extended by TApplicationComponent
Extended by TControl implements IRenderable, IBindable
Extended by THead
Package: System\Web\UI
Copyright: Copyright © 2005-2014 PradoSoft
License: http://www.pradosoft.com/license/
Author: Marcus Nyeholt <tanus@users.sourceforge.net> and Qiang Xue <qiang.xue@gmail.com>
Since: 3.0
Located at Web/UI/WebControls/THead.php
Methods summary
public
# onInit( TEventParameter $param )

Registers the head control with the current page. This method is invoked when the control enters 'Init' stage. The method raises 'Init' event. If you override this method, be sure to call the parent implementation so that the event handlers can be invoked.

Registers the head control with the current page. This method is invoked when the control enters 'Init' stage. The method raises 'Init' event. If you override this method, be sure to call the parent implementation so that the event handlers can be invoked.

Parameters

$param
TEventParameter
event parameter to be passed to the event handlers

Overrides

TControl::onInit()
public
# addParsedObject( string|TComponent $object )

Processes an object that is created during parsing template. This method adds TMetaTag components into the getMetaTags MetaTags collection of the head control.

Processes an object that is created during parsing template. This method adds TMetaTag components into the getMetaTags MetaTags collection of the head control.

Parameters

$object
string|TComponent
text string or component parsed and instantiated in template

See

TComponent::createdOnTemplate()

Overrides

TControl::addParsedObject()
public string
# getTitle( )

Returns

string
the page title.
public
# setTitle( string $value )

Sets the page title. This title will be rendered only if the TPage::getTitle Title property of the page is empty.

Sets the page title. This title will be rendered only if the TPage::getTitle Title property of the page is empty.

Parameters

$value
string
the page title.
public string
# getBaseUrl( )

Returns

string
base URL of the page. This URL is rendered as the 'href' attribute of <base> tag. Defaults to ''.
public
# setBaseUrl( string $url )

Parameters

$url
string
base URL of the page. This URL is rendered as the 'href' attribute of <base> tag.
public string
# getShortcutIcon( )

Returns

string
the URL for the shortcut icon of the page. Defaults to ''.
public
# setShortcutIcon( string $url )

Parameters

$url
string
the URL for the shortcut icon of the page.
public TMetaTagCollection
# getMetaTags( )

Returns

TMetaTagCollection
meta tag collection
public
# render( THtmlWriter $writer )

Renders the head control.

Renders the head control.

Parameters

$writer
THtmlWriter
the writer for rendering purpose.

Overrides

TControl::render()
Methods inherited from TControl
__construct(), __get(), addToPostDataLoader(), addedControl(), applyStyleSheetSkin(), autoBindProperty(), autoDataBindProperties(), bindProperty(), broadcastEvent(), bubbleEvent(), clearChildState(), clearControlState(), clearNamingContainer(), clearViewState(), convertUniqueIdToClientId(), createChildControls(), createControlCollection(), dataBind(), dataBindChildren(), dataBindProperties(), ensureChildControls(), findControl(), findControlsByID(), findControlsByType(), focus(), getAdapter(), getAllowChildControls(), getAttribute(), getAttributes(), getChildControlsCreated(), getClientID(), getControlStage(), getControlState(), getControls(), getCustomData(), getEnableTheming(), getEnableViewState(), getEnabled(), getHasAdapter(), getHasAttributes(), getHasChildInitialized(), getHasControls(), getHasInitialized(), getHasLoaded(), getHasLoadedPostData(), getHasPreRendered(), getID(), getIsSkinApplied(), getNamingContainer(), getPage(), getParent(), getRegisteredObject(), getSkinID(), getSourceTemplateControl(), getTemplateControl(), getUniqueID(), getViewState(), getVisible(), hasAttribute(), initRecursive(), isDescendentOf(), isObjectRegistered(), loadRecursive(), loadState(), loadStateRecursive(), onDataBinding(), onLoad(), onPreRender(), onUnload(), preRenderRecursive(), raiseBubbleEvent(), registerObject(), removeAttribute(), removedControl(), renderChildren(), renderControl(), saveState(), saveStateRecursive(), setAdapter(), setAttribute(), setChildControlsCreated(), setControlStage(), setControlState(), setCustomData(), setEnableTheming(), setEnableViewState(), setEnabled(), setID(), setPage(), setSkinID(), setTemplateControl(), setViewState(), setVisible(), trackViewState(), traverseChildControls(), unbindProperty(), unloadRecursive(), unregisterObject()
Methods inherited from TApplicationComponent
getApplication(), getRequest(), getResponse(), getService(), getSession(), getUser(), publishAsset(), publishFilePath()
Methods inherited from TComponent
__call(), __destruct(), __isset(), __set(), __sleep(), __unset(), __wakeup(), asa(), attachBehavior(), attachBehaviors(), attachClassBehavior(), attachEventHandler(), canGetProperty(), canSetProperty(), clearBehaviors(), createdOnTemplate(), detachBehavior(), detachBehaviors(), detachClassBehavior(), detachEventHandler(), disableBehavior(), disableBehaviors(), enableBehavior(), enableBehaviors(), evaluateExpression(), evaluateStatements(), fxAttachClassBehavior(), fxDetachClassBehavior(), getAutoGlobalListen(), getBehaviorsEnabled(), getClassHierarchy(), getEventHandlers(), getListeningToGlobalEvents(), getSubProperty(), hasEvent(), hasEventHandler(), hasProperty(), isa(), listen(), raiseEvent(), setSubProperty(), unlisten()
Constants inherited from TControl
AUTOMATIC_ID_PREFIX, CLIENT_ID_SEPARATOR, CS_CHILD_INITIALIZED, CS_CONSTRUCTED, CS_INITIALIZED, CS_LOADED, CS_PRERENDERED, CS_STATE_LOADED, ID_FORMAT, ID_SEPARATOR, IS_CHILD_CREATED, IS_CREATING_CHILD, IS_DISABLE_THEMING, IS_DISABLE_VIEWSTATE, IS_ID_SET, IS_SKIN_APPLIED, IS_STYLESHEET_APPLIED, RF_ADAPTER, RF_AUTO_BINDINGS, RF_CHILD_STATE, RF_CONTROLS, RF_CONTROLSTATE, RF_DATA_BINDINGS, RF_EVENTS, RF_NAMED_CONTROLS, RF_NAMED_CONTROLS_ID, RF_NAMED_OBJECTS, RF_SKIN_ID
Constants inherited from TComponent
GLOBAL_RAISE_EVENT_LISTENER
Terms of Service | Contact Us
PRADO v3.2.4 API Manual API documentation generated by ApiGen 2.8.0
Copyright © 2006-2014 by the PRADO Group.
Powered by PRADO