Class THyperLink

Description

Implements interfaces:

THyperLink class

THyperLink displays a hyperlink on a page. The hyperlink URL is specified via the NavigateUrl property, and link text is via the Text property. It is also possible to display an image by setting the ImageUrl property. In this case, Text is displayed as the alternate text of the image. The link target is specified via the Target property. If both ImageUrl and Text are empty, the content enclosed within the control tag will be rendered.

  • author: Qiang Xue <qiang.xue@gmail.com>
  • version: $Id: THyperLink.php 2996 2011-06-20 15:24:57Z ctrlaltca@gmail.com $
  • since: 3.0

Located in /Web/UI/WebControls/THyperLink.php (line 30)

TComponent
   |
   --TApplicationComponent
      |
      --TControl
         |
         --TWebControl
            |
            --THyperLink
Direct descendents
Class Description
TActiveHyperLink TActiveHyperLink class.
Method Summary
TImage createImage (string $imageUrl)
string getData ()
string getImageHeight ()
string getImageUrl ()
string getImageWidth ()
string getNavigateUrl ()
string getTagName ()
string getTarget ()
string getText ()
void renderContents (THtmlWriter $writer)
void setData (string $value)
void setImageHeight (string $value)
void setImageUrl (string $value)
void setImageWidth (string $value)
void setNavigateUrl (string $value)
void setTarget (string $value)
void setText (string $value)
Variables

Inherited Variables

Inherited from TWebControl

TWebControl::$_decorator
Methods
addAttributesToRender (line 44)

Adds attributes related to a hyperlink element to renderer.

  • access: protected
void addAttributesToRender (THtmlWriter $writer)
  • THtmlWriter $writer: the writer used for the rendering purpose

Redefinition of:
TWebControl::addAttributesToRender()
Adds attribute name-value pairs to renderer.
createImage (line 83)

Gets the TImage for rendering the ImageUrl property. This is not for creating dynamic images.

  • return: image control for rendering.
  • access: protected
TImage createImage (string $imageUrl)
  • string $imageUrl: image url.
getData (line 192)

Returns the URL to link to when the THyperLink component is clicked.

This method is required by IDataRenderer. It is the same as getText().

string getData ()
getImageHeight (line 119)
  • return: height of the image in the THyperLink
  • access: public
string getImageHeight ()
getImageUrl (line 136)
  • return: the location of the image file for the THyperLink
  • access: public
string getImageUrl ()
getImageWidth (line 153)
  • return: width of the image in the THyperLink
  • access: public
string getImageWidth ()
getNavigateUrl (line 170)
  • return: the URL to link to when the THyperLink component is clicked.
  • access: public
string getNavigateUrl ()
getTagName (line 35)
  • return: tag name of the hyperlink
  • access: protected
string getTagName ()

Redefinition of:
TWebControl::getTagName()
Returns the tag name used for this control.
getTarget (line 213)
  • return: the target window or frame to display the Web page content linked to when the THyperLink component is clicked.
  • access: public
string getTarget ()
getText (line 102)
  • return: the text caption of the THyperLink
  • access: public
string getText ()
renderContents (line 60)

Renders the body content of the hyperlink.

  • access: public
void renderContents (THtmlWriter $writer)

Redefinition of:
TWebControl::renderContents()
Renders the body content enclosed between the control tag.
setData (line 205)

Sets the URL to link to when the THyperLink component is clicked.

This method is required by IDataRenderer. It is the same as setText().

void setData (string $value)
  • string $value: the text caption to be set
setImageHeight (line 128)

Sets the height of the image in the THyperLink

  • access: public
void setImageHeight (string $value)
  • string $value: height of the image in the THyperLink
setImageUrl (line 145)

Sets the location of image file of the THyperLink.

  • access: public
void setImageUrl (string $value)
  • string $value: the image file location

Redefined in descendants as:
setImageWidth (line 162)

Sets the width of the image in the THyperLink

  • access: public
void setImageWidth (string $value)
  • string $value: width of the image
setNavigateUrl (line 179)

Sets the URL to link to when the THyperLink component is clicked.

  • access: public
void setNavigateUrl (string $value)
  • string $value: the URL

Redefined in descendants as:
setTarget (line 222)

Sets the target window or frame to display the Web page content linked to when the THyperLink component is clicked.

  • access: public
void setTarget (string $value)
  • string $value: the target window, valid values include '_blank', '_parent', '_self', '_top' and empty string.

Redefined in descendants as:
  • TActiveHyperLink::setTarget() : Sets the target window or frame to display the Web page content linked to when the THyperLink component is clicked.
setText (line 111)

Sets the text caption of the THyperLink.

  • access: public
void setText (string $value)
  • string $value: the text caption to be set

Redefined in descendants as:

Inherited Methods

Inherited From TWebControl

TWebControl::addAttributesToRender()
TWebControl::clearStyle()
TWebControl::copyBaseAttributes()
TWebControl::createStyle()
TWebControl::getAccessKey()
TWebControl::getBackColor()
TWebControl::getBorderColor()
TWebControl::getBorderStyle()
TWebControl::getBorderWidth()
TWebControl::getCssClass()
TWebControl::getDecorator()
TWebControl::getDisplay()
TWebControl::getEnsureId()
TWebControl::getFont()
TWebControl::getForeColor()
TWebControl::getHasStyle()
TWebControl::getHeight()
TWebControl::getStyle()
TWebControl::getTabIndex()
TWebControl::getTagName()
TWebControl::getToolTip()
TWebControl::getWidth()
TWebControl::onPreRender()
TWebControl::render()
TWebControl::renderBeginTag()
TWebControl::renderContents()
TWebControl::renderEndTag()
TWebControl::setAccessKey()
TWebControl::setBackColor()
TWebControl::setBorderColor()
TWebControl::setBorderStyle()
TWebControl::setBorderWidth()
TWebControl::setCssClass()
TWebControl::setDisplay()
TWebControl::setEnsureId()
TWebControl::setForeColor()
TWebControl::setHeight()
TWebControl::setStyle()
TWebControl::setTabIndex()
TWebControl::setToolTip()
TWebControl::setWidth()

Inherited From TControl

TControl::__construct()
TControl::addedControl()
TControl::addParsedObject()
TControl::addToPostDataLoader()
TControl::applyStyleSheetSkin()
TControl::autoBindProperty()
TControl::autoDataBindProperties()
TControl::bindProperty()
TControl::broadcastEvent()
TControl::bubbleEvent()
TControl::clearChildState()
TControl::clearControlState()
TControl::clearNamingContainer()
TControl::clearViewState()
TControl::convertUniqueIdToClientId()
TControl::createChildControls()
TControl::createControlCollection()
TControl::dataBind()
TControl::dataBindChildren()
TControl::dataBindProperties()
TControl::ensureChildControls()
TControl::findControl()
TControl::findControlsByID()
TControl::findControlsByType()
TControl::focus()
TControl::getAdapter()
TControl::getAllowChildControls()
TControl::getAttribute()
TControl::getAttributes()
TControl::getChildControlsCreated()
TControl::getClientID()
TControl::getControls()
TControl::getControlStage()
TControl::getControlState()
TControl::getCustomData()
TControl::getEnabled()
TControl::getEnableTheming()
TControl::getEnableViewState()
TControl::getHasAdapter()
TControl::getHasAttributes()
TControl::getHasChildInitialized()
TControl::getHasControls()
TControl::getHasInitialized()
TControl::getHasLoaded()
TControl::getHasLoadedPostData()
TControl::getHasPreRendered()
TControl::getID()
TControl::getIsSkinApplied()
TControl::getNamingContainer()
TControl::getPage()
TControl::getParent()
TControl::getRegisteredObject()
TControl::getSkinID()
TControl::getSourceTemplateControl()
TControl::getTemplateControl()
TControl::getUniqueID()
TControl::getViewState()
TControl::getVisible()
TControl::hasAttribute()
TControl::initRecursive()
TControl::isDescendentOf()
TControl::isObjectRegistered()
TControl::loadRecursive()
TControl::loadState()
TControl::loadStateRecursive()
TControl::onDataBinding()
TControl::onInit()
TControl::onLoad()
TControl::onPreRender()
TControl::onUnload()
TControl::preRenderRecursive()
TControl::raiseBubbleEvent()
TControl::registerObject()
TControl::removeAttribute()
TControl::removedControl()
TControl::render()
TControl::renderChildren()
TControl::renderControl()
TControl::saveState()
TControl::saveStateRecursive()
TControl::setAdapter()
TControl::setAttribute()
TControl::setChildControlsCreated()
TControl::setControlStage()
TControl::setControlState()
TControl::setCustomData()
TControl::setEnabled()
TControl::setEnableTheming()
TControl::setEnableViewState()
TControl::setID()
TControl::setPage()
TControl::setSkinID()
TControl::setTemplateControl()
TControl::setViewState()
TControl::setVisible()
TControl::trackViewState()
TControl::traverseChildControls()
TControl::unbindProperty()
TControl::unloadRecursive()
TControl::unregisterObject()
TControl::__get()

Inherited From TApplicationComponent

TApplicationComponent::getApplication()
TApplicationComponent::getRequest()
TApplicationComponent::getResponse()
TApplicationComponent::getService()
TApplicationComponent::getSession()
TApplicationComponent::getUser()
TApplicationComponent::publishAsset()
TApplicationComponent::publishFilePath()

Inherited From TComponent

TComponent::addParsedObject()
TComponent::attachEventHandler()
TComponent::canGetProperty()
TComponent::canSetProperty()
TComponent::createdOnTemplate()
TComponent::detachEventHandler()
TComponent::evaluateExpression()
TComponent::evaluateStatements()
TComponent::getEventHandlers()
TComponent::getSubProperty()
TComponent::hasEvent()
TComponent::hasEventHandler()
TComponent::hasProperty()
TComponent::raiseEvent()
TComponent::setSubProperty()
TComponent::__call()
TComponent::__get()
TComponent::__set()
TComponent::__sleep()
TComponent::__wakeup()
Class Constants

Documentation generated on Mon, 25 Jun 2012 14:38:24 +0200 by phpDocumentor 1.4.3