Mambots Development
Mambots are pluggable elements that perform a specific function when they are triggered.
These are event triggers for mambots:
onPrepareContent
function function_name( $published, &$row, $mask=0, $page=0 )
$row is a variable reference to the content conject:
id, title, title_alias, introtext, sectionid, state, catid, created, created_by, create_by_alias, modified, modified_by, checked_out, checked_out_time, publish_up, publish_down, images, urls, ordering, metakey, metadesc, access, hits, readmore, author, usertype, section, category, groups, sec_id, cat_id, text, _Itemid, Itemid_link, link_on, link_text
onAfterDisplayTitle
onBeforeDisplayContent
onAfterDisplayContent
onInitEditor
function function_name()
onGetEditorContents
function function_name( $editorArea, $hiddenField )
onEditorArea
function function_name( $name, $content, $hiddenField, $width, $height, $col, $row )
onSearch
function function_name( $text )
Writing a Mambot
1. register function:
$_PLUGINS->registerFunction( 'event_name', 'function_name' );
2. implement the function:
function function_name( parameters... )