Index of /_user/_plugins/input/textarea
Name Last modified Size Description
Parent Directory 16-Dec-2007 22:58 -
_PKING/ 16-Dec-2007 22:58 -
bbc/ 16-Dec-2007 22:58 -
editor.css 16-Dec-2007 22:58 4k
editor.js 16-Dec-2007 22:58 3k
editor.tmpl 16-Dec-2007 22:58 2k
extapps/ 16-Dec-2007 22:58 -
plugin.php 16-Dec-2007 22:58 1k
preview.inc 16-Dec-2007 22:58 1k
render.inc 16-Dec-2007 22:58 6k
testrender.php 16-Dec-2007 22:58 2k
BBCODE Plugin
Installation
Unpack plugin_input_textarea into /_dcc/_plugins or /_user/_plugins
This plugin uses icons from the TinyMCE distro and famfamfam's silk icons converted to .gif
The famfamfam icon set is available as an addon package.
Integration
While the <plugin> command will render the page, to active re-rendering and previewing you'll need to manually
load two additional modules
<plugindir>/input/textaera/render.inc
<plugindir>/input/textarea/preview.inc
These are best loaded from /_user/localconfig.inc
Firing it up:
<plugin id="input::textarea"
formname="<name on form>"
value="<initial value>"
[tabindex="<index#>"]
[onfocus="<onfocusevent>"]
[onblur="<onblurevent>"]
/>
Preview option
Manual injection is needed to get this working.
In your DCX application section:
$xajax = new xajax;
$xajax->RegisterFunction("dcxBBCodePreview");
$xajax->ProcessRequests();
ob_start();
$xajax->PrintJavaScript(XAJAX_PATH);
$XAJAX_JS = ob_get_contents();
ob_end_clean();
In your template or CONTENT segment:
You call a pre-defined JS function called dcxBBEPreview
void dcxBBEPreview(object TextAreaControl)
TextAreaControl is the object (not the value) of the bbcode textarea
eg:
<input type=button value="Preview Post" onclick="dcxBBEPreview(document.<form>.<field>)">
NOTE: It's entirely possible to just use the render and preview to sort out any text input although using
the plugin makes editing much easier
--END--