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 THtmlArea4

THtmlArea4 class

THtmlArea4 wraps the visual editing functionalities provided by the version 4 of TinyMCE project http://tinymce.com/. It has been developed as a plug'n'play substitute for THtmlArea, that is based on the previous iteration (version 3) of the same project. Please note that both components can't be used together in the same page.

THtmlArea displays a WYSIWYG text area on the Web page for user input in the HTML format. The text displayed in the THtmlArea component is specified or determined by using the Text property.

To enable the visual editting on the client side, set the property EnableVisualEdit to true (which is default value). To set the size of the editor when the visual editting is enabled, set the Width and Height properties instead of Columns and Rows because the latter has no meaning under the situation.

The default editor gives only the basic tool bar. To change or add additional tool bars, use the setOptions Options property to add additional editor options with each options on a new line. See http://www.tinymce.com/wiki.php/Configuration for a list of options. The options can be change/added as shown in the following example.

<com:THtmlArea>
      <prop:Options>
        language : "de"
        plugins: [ advlist anchor autolink autoresize autosave bbcode charmap code contextmenu directionality emoticons fullpage fullscreen hr image importcss insertdatetime layer legacyoutput link lists media nonbreaking noneditable pagebreak paste preview print save searchreplace spellchecker tabfocus table template textcolor visualblocks visualchars wordcount ]
        toolbar: "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image     | print preview media",
        statusbar: false
     </prop:Options>
</com:THtmlArea>
TComponent
Extended by TApplicationComponent
Extended by TControl implements IRenderable, IBindable
Extended by TWebControl implements IStyleable
Extended by TTextBox implements IPostBackDataHandler, IValidatable, IDataRenderer
Extended by THtmlArea4
Package: System\Web\UI\WebControls
Copyright: Copyright © 2005-2014 PradoSoft
License: http://www.pradosoft.com/license/
Author: Wei Zhuo <weizhuo[at]gmail[dot]com>
Since: 3.0
Located at Web/UI/WebControls/THtmlArea4.php
Methods summary
public
# __construct( )

Constructor. Sets default width and height.

Constructor. Sets default width and height.

Overrides

TControl::__construct()
public string
# getTextMode( )

Overrides the parent implementation. TextMode for THtmlArea control is always 'MultiLine'

Overrides the parent implementation. TextMode for THtmlArea control is always 'MultiLine'

Returns

string
the behavior mode of the THtmlArea component.

Overrides

TTextBox::getTextMode()
public
# setTextMode( string $value )

Overrides the parent implementation. TextMode for THtmlArea is always 'MultiLine' and cannot be changed to others.

Overrides the parent implementation. TextMode for THtmlArea is always 'MultiLine' and cannot be changed to others.

Parameters

$value
string
the text mode

Throws

TInvalidDataValueException
if the input value is not a valid text mode.

Overrides

TTextBox::setTextMode()
public boolean
# getAutoPostBack( )

Returns

boolean
whether change of the content should cause postback. Return false if EnableVisualEdit is true.

Overrides

TTextBox::getAutoPostBack()
public boolean
# getEnableVisualEdit( )

Returns

boolean
whether to show WYSIWYG text editor. Defaults to true.
public
# setEnableVisualEdit( boolean $value )

Sets whether to show WYSIWYG text editor.

Sets whether to show WYSIWYG text editor.

Parameters

$value
boolean
whether to show WYSIWYG text editor
public string
# getCulture( )

Gets the current culture.

Gets the current culture.

Returns

string
current culture, e.g. de_AT.
public
# setCulture( string $value )

Sets the culture/language for the html area

Sets the culture/language for the html area

Parameters

$value
string
a culture string, e.g. de_AT.
public string
# getOptions( )

Gets the list of options for the WYSIWYG (TinyMCE) editor

Gets the list of options for the WYSIWYG (TinyMCE) editor

Returns

string
options

See

http://www.tinymce.com/wiki.php/Configuration
public
# setOptions( string $value )

Sets the list of options for the WYSIWYG (TinyMCE) editor

Sets the list of options for the WYSIWYG (TinyMCE) editor

Parameters

$value
string
options

See

http://www.tinymce.com/wiki.php/Configuration
public
# setCustomPluginPath( string $value )

Parameters

$value
string
path to custom plugins to be copied.
public string
# getCustomPluginPath( )

Returns

string
path to custom plugins to be copied.
public boolean
# getEnableCompression( )

Deprecated

since 3.2.3: tinyMCE 4 doesn't support this anymore

Returns

boolean
enable compression of the javascript files, default is true.
public
# setEnableCompression( boolean $value )

Deprecated

since 3.2.3: tinyMCE 4 doesn't support this anymore

Parameters

$value
boolean
enable compression of the javascript files, default is true.
protected
# addAttributesToRender( THtmlWriter $writer )

Adds attribute name-value pairs to renderer. This method overrides the parent implementation by registering additional javacript code.

Adds attribute name-value pairs to renderer. This method overrides the parent implementation by registering additional javacript code.

Parameters

$writer
THtmlWriter
the writer used for the rendering purpose

Overrides

TTextBox::addAttributesToRender()
public array
# getAvailablePlugins( )

Returns a list of plugins to be loaded. Override this method to customize.

Returns a list of plugins to be loaded. Override this method to customize.

Returns

array
list of plugins to be loaded
public array
# getAvailableThemes( )

Returns

array
list of available themese
protected
# getCompressionOptions( )

Deprecated

since 3.2.3. tinyMCE4 doesn's use this anymore
protected
# loadJavascriptLibrary( )
protected
# registerEditorClientScript( mixed $writer )

Registers the editor javascript file and code to initialize the editor.

Registers the editor javascript file and code to initialize the editor.

protected string
# getScriptUrl( )

Returns

string
editor script URL.
protected string
# getScriptDeploymentPath( )

Gets the editor script base URL by publishing the tarred source via TTarAssetManager.

Gets the editor script base URL by publishing the tarred source via TTarAssetManager.

Returns

string
URL base path to the published editor script
protected
# copyCustomPlugins( mixed $url )
protected array
# getEditorOptions( )

Default editor options gives basic tool bar only.

Default editor options gives basic tool bar only.

Returns

array
editor initialization options.
protected array
# parseEditorOptions( mixed $string )

Parse additional options set in the Options property.

Parse additional options set in the Options property.

Returns

array
additional custom options
protected string
# getLanguageSuffix( mixed $culture )

Returns

string
localized editor interface language extension.
protected string
# getClientClassName( )

Gets the name of the javascript class responsible for performing postback for this control. This method overrides the parent implementation.

Gets the name of the javascript class responsible for performing postback for this control. This method overrides the parent implementation.

Returns

string
the javascript class name

Overrides

TTextBox::getClientClassName()
Methods inherited from TTextBox
getAutoCompleteType(), getAutoTrim(), getCausesValidation(), getColumns(), getData(), getDataChanged(), getEnableClientScript(), getIsValid(), getMaxLength(), getPersistPassword(), getPostBackOptions(), getReadOnly(), getRows(), getSafeText(), getSafeTextParser(), getTagName(), getText(), getValidationGroup(), getValidationPropertyValue(), getWrap(), loadPostData(), onTextChanged(), raisePostDataChangedEvent(), renderBeginTag(), renderClientControlScript(), renderContents(), setAutoCompleteType(), setAutoPostBack(), setAutoTrim(), setCausesValidation(), setColumns(), setData(), setEnableClientScript(), setIsValid(), setMaxLength(), setPersistPassword(), setReadOnly(), setRows(), setText(), setValidationGroup(), setWrap()
Methods inherited from TWebControl
clearStyle(), copyBaseAttributes(), createStyle(), getAccessKey(), getBackColor(), getBorderColor(), getBorderStyle(), getBorderWidth(), getCssClass(), getDecorator(), getDisplay(), getEnsureId(), getFont(), getForeColor(), getHasStyle(), getHeight(), getStyle(), getTabIndex(), getToolTip(), getWidth(), onPreRender(), render(), renderEndTag(), setAccessKey(), setBackColor(), setBorderColor(), setBorderStyle(), setBorderWidth(), setCssClass(), setDisplay(), setEnsureId(), setForeColor(), setHeight(), setStyle(), setTabIndex(), setToolTip(), setWidth()
Methods inherited from TControl
__get(), addParsedObject(), 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(), onInit(), onLoad(), 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 TTextBox
DEFAULT_COLUMNS, DEFAULT_ROWS
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
Properties inherited from TWebControl
$_decorator
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