[ Index ] |
|
Code source de CMS made simple 1.0.5 |
[Code source] [Imprimer] [Statistiques]
(pas de description)
Poids: | 2312 lignes (66 kb) |
Inclus ou requis: | 0 fois |
Référencé: | 0 fois |
Nécessite: | 0 fichiers |
CMSModule:: (180 méthodes):
CMSModule()
LoadTemplateMethods()
LoadLangMethods()
LoadFormMethods()
LoadRedirectMethods()
LoadMiscMethods()
GetAbout()
GetHelpPage()
GetName()
GetModulePath()
GetFriendlyName()
GetVersion()
MinimumCMSVersion()
MaximumCMSVersion()
GetHelp()
GetHeaderHTML()
SuppressAdminOutput()
RegisterRoute()
GetParameters()
SetParameters()
CreateParameter()
GetDescription()
GetAdminDescription()
IsAdminOnly()
GetChangeLog()
GetAuthor()
GetAuthorEmail()
HasContentType()
RegisterContentType()
GetContentTypeInstance()
IsExclusive()
Install()
InstallPostMessage()
Uninstall()
UninstallPreMessage()
UninstallPostMessage()
Upgrade()
AllowAutoInstall()
AllowAutoUpgrade()
GetDependencies()
CheckForDependents()
CreateXMLPackage()
HasAdmin()
HasAdminBuffering()
GetAdminSection()
VisibleToAdminUser()
IsContentModule()
IsPluginModule()
IsSoapModule()
LoginPost()
LogoutPost()
AddUserPre()
AddUserPost()
EditUserPre()
EditUserPost()
DeleteUserPre()
DeleteUserPost()
AddGroupPre()
AddGroupPost()
EditGroupPre()
EditGroupPost()
DeleteGroupPre()
DeleteGroupPost()
AddTemplatePre()
AddTemplatePost()
EditTemplatePre()
EditTemplatePost()
DeleteTemplatePre()
DeleteTemplatePost()
TemplatePreCompile()
TemplatePostCompile()
ContentEditPre()
ContentEditPost()
ContentDeletePre()
ContentDeletePost()
AddStylesheetPre()
AddStylesheetPost()
EditStylesheetPre()
EditStylesheetPost()
DeleteStylesheetPre()
DeleteStylesheetPost()
AddHtmlBlobPre()
AddHtmlBlobPost()
EditHtmlBlobPre()
EditHtmlBlobPost()
DeleteHtmlBlobPre()
DeleteHtmlBlobPost()
GlobalContentPreCompile()
GlobalContentPostCompile()
ContentTemplate()
ContentStylesheet()
ContentTitle()
ContentData()
ContentHtmlBlob()
ContentPreRender()
ContentPreCompile()
ContentPostCompile()
ContentPostRenderNonCached()
ContentPostRender()
SmartyPreCompile()
SmartyPostCompile()
IsWYSIWYG()
WYSIWYGActive()
WYSIWYGPageForm()
WYSIWYGPageFormSubmit()
WYSIWYGGenerateHeader()
WYSIWYGGenerateBody()
WYSIWYGTextarea()
ShowInWYSIWYG()
DoAction()
DoActionBase()
CreateFieldsetStart()
CreateFieldsetEnd()
CreateFrontendFormStart()
CreateFormStart()
CreateFormEnd()
CreateInputText()
CreateLabelForInput()
CreateInputTextWithLabel()
CreateInputFile()
CreateInputPassword()
CreateInputHidden()
CreateInputCheckbox()
CreateInputSubmit()
CreateInputReset()
CreateFileUploadInput()
CreateInputDropdown()
CreateInputSelectList()
CreateInputRadioGroup()
CreateTextArea()
CreateFrontendLink()
CreateLink()
CreateContentLink()
CreateReturnLink()
RedirectForFrontEnd()
Redirect()
RedirectContent()
GetModuleInstance()
DefaultLanguage()
Lang()
ListTemplates()
GetTemplate()
GetTemplateFromFile()
SetTemplate()
DeleteTemplate()
IsFileTemplateCached()
ProcessTemplate()
IsDatabaseTemplateCached()
ProcessTemplateFromData()
ProcessTemplateFromDatabase()
ListUserTags()
CallUserTag()
StartTabHeaders()
SetTabHeader()
EndTabHeaders()
StartTabContent()
EndTabContent()
StartTab()
EndTab()
AdminStyle()
SetContentType()
Audit()
CreatePermission()
CheckPermission()
RemovePermission()
GetPreference()
SetPreference()
RemovePreference()
CreatePagination()
ShowMessage()
ShowErrors()
AddEventHandler()
CreateEvent()
DoEvent()
GetEventDescription()
GetEventHelp()
HandlesEvents()
RemoveEvent()
RemoveEventHandler()
SendEvent()
CMSModule() X-Ref |
Pas de description |
LoadTemplateMethods() X-Ref |
Pas de description |
LoadLangMethods() X-Ref |
Pas de description |
LoadFormMethods() X-Ref |
Pas de description |
LoadRedirectMethods() X-Ref |
Pas de description |
LoadMiscMethods() X-Ref |
Pas de description |
GetAbout() X-Ref |
Returns a sufficient about page for a module |
GetHelpPage() X-Ref |
Returns a sufficient help page for a module this function should not be overridden |
GetName() X-Ref |
Returns the name of the module |
GetModulePath() X-Ref |
Returns the full path of the module directory. |
GetFriendlyName() X-Ref |
Returns a translatable name of the module. For modulues who's names can probably be translated into another language (like News) |
GetVersion() X-Ref |
Returns the version of the module |
MinimumCMSVersion() X-Ref |
Returns the minimum version necessary to run this version of the module. |
MaximumCMSVersion() X-Ref |
Returns the maximum version necessary to run this version of the module. |
GetHelp($lang = 'en_US') X-Ref |
Returns the help for the module param: string Optional language that the admin is using. If that language |
GetHeaderHTML() X-Ref |
Returns XHTML that nees to go between the <head> tags |
SuppressAdminOutput(&$request) X-Ref |
Use this method to prevent the admin interface from outputting header, footer, theme, etc, so your module can output files directly to the administrator. Do this by returning true. |
RegisterRoute($routeregex, $defaults = array() X-Ref |
Register a route to use for pretty url parsing param: string Route to register param: array Defaults for parameters that might not be included in the url |
GetParameters() X-Ref |
Returns a list of parameters and their help strings in a hash. This is generally used internally. |
SetParameters() X-Ref |
Setup your parameters here. It doesn't have to be here, but it makes the code more legible. |
CreateParameter($param, $defaultval='', $helpstring='', $optional=true) X-Ref |
Pas de description |
GetDescription($lang = 'en_US') X-Ref |
Returns a short description of the module param: string Optional language that the admin is using. If that language |
GetAdminDescription($lang = 'en_US') X-Ref |
Returns a description of what the admin link does. param: string Optional language that the admin is using. If that language |
IsAdminOnly() X-Ref |
Returns whether this module should only be loaded from the admin |
GetChangeLog() X-Ref |
Returns the changelog for the module |
GetAuthor() X-Ref |
Returns the name of the author |
GetAuthorEmail() X-Ref |
Returns the email address of the author |
HasContentType() X-Ref |
Pas de description |
RegisterContentType($name, $file, $friendlyname = '') X-Ref |
Pas de description |
GetContentTypeInstance() X-Ref |
Return an instance of the new content type |
IsExclusive() X-Ref |
Pas de description |
Install() X-Ref |
Function that will get called as module is installed. This function should do any initialization functions including creating database tables. It should return a string message if there is a failure. Returning nothing (FALSE) will allow the install procedure to proceed. |
InstallPostMessage() X-Ref |
Display a message after a successful installation of the module. |
Uninstall() X-Ref |
Function that will get called as module is uninstalled. This function should remove any database tables that it uses and perform any other cleanup duties. It should return a string message if there is a failure. Returning nothing (FALSE) will allow the uninstall procedure to proceed. |
UninstallPreMessage() X-Ref |
Display a message and a Yes/No dialog before doing an uninstall. Returning noting (FALSE) will go right to the uninstall. |
UninstallPostMessage() X-Ref |
Display a message after a successful uninstall of the module. |
Upgrade($oldversion, $newversion) X-Ref |
Function to perform any upgrade procedures. This is mostly used to for updating databsae tables, but can do other duties as well. It should return a string message if there is a failure. Returning nothing (FALSE) will allow the upgrade procedure to proceed. Upgrades should have a path so that they can be upgraded from more than one version back. While not a requirement, it makes life easy for your users. param: string The version we are upgrading from param: string The version we are upgrading to |
AllowAutoInstall() X-Ref |
Returns whether or not modules should be autoupgraded while upgrading CMS versions. Generally only useful for modules included with the CMS base install, but there could be a situation down the road where we have different distributions with different modules included in them. Defaults to TRUE, as there is not many reasons to not allow it. |
AllowAutoUpgrade() X-Ref |
Returns whether or not modules should be autoupgraded while upgrading CMS versions. Generally only useful for modules included with the CMS base install, but there could be a situation down the road where we have different distributions with different modules included in them. Defaults to TRUE, as there is not many reasons to not allow it. |
GetDependencies() X-Ref |
Returns a list of dependencies and minimum versions that this module requires. It should return an hash, eg. return array('somemodule'=>'1.0', 'othermodule'=>'1.1'); |
CheckForDependents() X-Ref |
Checks to see if currently installed modules depend on this module. This is used by the plugins.php page to make sure that a module can't be uninstalled before any modules depending on it are uninstalled first. |
CreateXMLPackage( &$message, &$filecount ) X-Ref |
Creates an xml data package from the module directory. |
HasAdmin() X-Ref |
Return true if there is an admin for the module. Returns false by default. |
HasAdminBuffering() X-Ref |
Should we use output buffering in the admin for this module? |
GetAdminSection() X-Ref |
Returns which admin section this module belongs to. this is used to place the module in the appropriate admin navigation section. Valid options are currently: content, layout, files, usersgroups, extensions, preferences, admin |
VisibleToAdminUser() X-Ref |
Returns true or false, depending on whether the user has the right permissions to see the module in their Admin menus. Defaults to true. |
IsContentModule() X-Ref |
Returns true if the module should be treated as a content module. Returns false by default. |
IsPluginModule() X-Ref |
Returns true if the module should be treated as a plugin module (like {cms_module module='name'}. Returns false by default. |
IsSoapModule() X-Ref |
Returns true if the module acts as a soap server |
LoginPost(&$user) X-Ref |
Called after a successful login. It sends the user object. param: User The user that just logged in |
LogoutPost() X-Ref |
Called after a successful logout. |
AddUserPre(&$user) X-Ref |
Called before a user is added to the database. Sends the user object. param: User The user that was just created |
AddUserPost(&$user) X-Ref |
Called after a user is added to the database. Sends the user object. param: User The user that was just created |
EditUserPre(&$user) X-Ref |
Called before a user is saved to the database. Sends the user object. param: User The user that was just edited |
EditUserPost(&$user) X-Ref |
Called after a user is saved to the database. Sends the user object. param: User The user that was just edited |
DeleteUserPre(&$user) X-Ref |
Called before a user is deleted from the database. Sends the user object. param: User The user that was just deleted |
DeleteUserPost(&$user) X-Ref |
Called after a user is deleted from the database. Sends the user object. param: User The user that was just deleted |
AddGroupPre(&$group) X-Ref |
Called before a group is added to the database. Sends the group object. param: Group The group that was just created |
AddGroupPost(&$group) X-Ref |
Called after a group is added to the database. Sends the group object. param: Group The group that was just created |
EditGroupPre(&$group) X-Ref |
Called before a group is saved to the database. Sends the group object. param: Group The group that was just edited |
EditGroupPost(&$group) X-Ref |
Called after a group is saved to the database. Sends the group object. param: Group The group that was just edited |
DeleteGroupPre(&$group) X-Ref |
Called before a group is deleted from the database. Sends the group object. param: Group The group that was just deleted |
DeleteGroupPost(&$group) X-Ref |
Called after a group is deleted from the database. Sends the group object. param: Group The group that was just deleted |
AddTemplatePre(&$template) X-Ref |
Called before a template is added to the database. Sends the template object. param: Template The template that was just created |
AddTemplatePost(&$template) X-Ref |
Called after a template is added to the database. Sends the template object. param: Template The template that was just created |
EditTemplatePre(&$template) X-Ref |
Called before a template is saved to the database. Sends the template object. param: Template The template that was just edited |
EditTemplatePost(&$template) X-Ref |
Called after a template is saved to the database. Sends the template object. param: Template The template that was just edited |
DeleteTemplatePre(&$template) X-Ref |
Called before a template is deleted from the database. Sends the template object. param: Template The template that was just deleted |
DeleteTemplatePost(&$template) X-Ref |
Called after a template is deleted from the database. Sends the template object. param: Template The template that was just deleted |
TemplatePreCompile(&$template) X-Ref |
Pas de description |
TemplatePostCompile(&$template) X-Ref |
Pas de description |
ContentEditPre(&$content) X-Ref |
------------------------------------------------------------------ General Content Related Functions ------------------------------------------------------------------ |
ContentEditPost(&$content) X-Ref |
Pas de description |
ContentDeletePre(&$content) X-Ref |
Pas de description |
ContentDeletePost(&$content) X-Ref |
Pas de description |
AddStylesheetPre(&$stylesheet) X-Ref |
Called before a Stylesheet is added to the database. Sends the stylesheet object. param: Stylesheet The stylesheet that was just created |
AddStylesheetPost(&$stylesheet) X-Ref |
Called after a stylesheet is added to the database. Sends the stylesheet object. param: Stylesheet The stylesheet that was just created |
EditStylesheetPre(&$stylesheet) X-Ref |
Called before a stylesheet is saved to the database. Sends the stylesheet object. param: stylesheet The stylesheet that was just edited |
EditStylesheetPost(&$stylesheet) X-Ref |
Called after a stylesheet is saved to the database. Sends the stylesheet object. param: stylesheet The stylesheet that was just edited |
DeleteStylesheetPre(&$stylesheet) X-Ref |
Called before a stylesheet is deleted from the database. Sends the stylesheet object. param: stylesheet The stylesheet that was just deleted |
DeleteStylesheetPost(&$stylesheet) X-Ref |
Called after a stylesheet is deleted from the database. Sends the stylesheet object. param: stylesheet The stylesheet that was just deleted |
AddHtmlBlobPre(&$htmlblob) X-Ref |
Called before an HTML blob is added to the database. Sends the html blob object. param: HtmlBlob The HTML blob that was just created |
AddHtmlBlobPost(&$htmlblob) X-Ref |
Called after an HTML blob is added to the database. Sends the html blob object. param: HtmlBlob The HTML blob that was just created |
EditHtmlBlobPre(&$htmlblob) X-Ref |
Called before an HTML blob is saved to the database. Sends the html blob object. param: HtmlBlob The HTML blob that was just edited |
EditHtmlBlobPost(&$htmlblob) X-Ref |
Called after an HTML blob is saved to the database. Sends the html blob object. param: HtmlBlob The HTML blob that was just edited |
DeleteHtmlBlobPre(&$htmlblob) X-Ref |
Called before an HTML blob is deleted from the database. Sends the html blob object. param: HtmlBlob The HTML blob that was just deleted |
DeleteHtmlBlobPost(&$htmlblob) X-Ref |
Called after an HTML blob is deleted from the database. Sends the html blob object. param: HtmlBlob The HTML blob that was just deleted |
GlobalContentPreCompile(&$gc) X-Ref |
Pas de description |
GlobalContentPostCompile(&$gc) X-Ref |
Pas de description |
ContentTemplate(&$template) X-Ref |
Called with the content of the template before it's sent to smarty for processing. Deprecated: This isn't called anymore. param: string The template text |
ContentStylesheet(&$stylesheet) X-Ref |
Called with the content of the stylesheet before it is pasted into the template. param: string The stylesheet text |
ContentTitle(&$title) X-Ref |
Called with the title before it is pasted into the template. Deprecated: This isn't called anymore. param: string The title text |
ContentData(&$content) X-Ref |
Called with the content data before it is pasted into the template. Deprecated: This isn't called anymore. Use ContentPreCompile. param: string The content text |
ContentHtmlBlob(&$htmlblob) X-Ref |
Called with the content of the html blob before it is pasted into the template (but after content is pasted in) Deprecated: This isn't called anymore. Use GlobalContentPreCompile. param: string The html blob text |
ContentPreRender(&$content) X-Ref |
Called before the pasted together template/content/html blobs/etc are sent to smarty for processing. Deprecated: Not useful anymore, since it's all handled separately now param: string The prerendered text |
ContentPreCompile(&$content) X-Ref |
Called before the content is sent off to smarty for processing. Basically overlaps with ContentPreRender, but it makes more sense to be named PreCompile. param: string The precompiled text |
ContentPostCompile(&$content) X-Ref |
Called right after smarty is done processing and ready to head off to the cache. Does the same as PostRenderNonCached, but with a better name. param: string The postcompiled text |
ContentPostRenderNonCached(&$content) X-Ref |
This serves no purpose anymore. Template, content and html blobs are never pushed together at any point and cached. Deprecated param: string The postrendered text |
ContentPostRender(&$content) X-Ref |
Called after content is sent to smarty for processing and right before display. Cached content will still call this function before display, but it is called EVERY time a page is requested. param: string The postrendered text |
SmartyPreCompile(&$content) X-Ref |
Called before any smarty "template" (content blocks/content tempaltes/modules) gets pushed off for compilation. (new in 0.12) param: string The precompiled text |
SmartyPostCompile(&$content) X-Ref |
Called after any smarty "template" (content blocks/content tempaltes/modules) is done being compiled by smarty, but before caching. (new in 0.12) param: string The precompiled text |
IsWYSIWYG() X-Ref |
Returns true if this module should be treated as a WYSIWYG module. It returns false be default. |
WYSIWYGActive() X-Ref |
Returns true if this wysiwyg should be considered active, eventhough it's not the choice of the user. Used for forcing a wysiwyg. returns false be default. |
WYSIWYGPageForm() X-Ref |
Returns content destined for the <form> tag. It's useful if javascript is needed for the onsubmit of the form. |
WYSIWYGPageFormSubmit() X-Ref |
This is a function that would be called before a form is submitted. Generally, a dropdown box or something similar that would force a submit of the form via javascript should put this in their onchange line as well so that the WYSIWYG can do any cleanups before the actual form submission takes place. |
WYSIWYGGenerateHeader($htmlresult='') X-Ref |
Returns header code specific to this WYSIWYG param: string The html-code of the page before replacing WYSIWYG-stuff |
WYSIWYGGenerateBody() X-Ref |
Returns body code specific to this WYSIWYG |
WYSIWYGTextarea($name='textarea',$columns='80',$rows='15',$encoding='',$content='',$stylesheet='') X-Ref |
Returns the textarea specific for this WYSIWYG. param: string HTML name of the textarea param: int Number of columns wide that the textarea should be param: int Number of rows long that the textarea should be param: string Encoding of the content param: string Content to show in the textarea param: string Stylesheet for content, if available |
ShowInWYSIWYG() X-Ref |
Returns whether or not this module should show in any module lists generated by a WYSIWYG. |
DoAction($name, $id, $params, $returnid='') X-Ref |
Used for navigation between "pages" of a module. Forms and links should pass an action with them so that the module will know what to do next. By default, DoAction will be passed 'default' and 'defaultadmin', depending on where the module was called from. If being used as a module or content type, 'default' will be passed. If the module was selected from the list on the admin menu, then 'defaultadmin' will be passed. param: string Name of the action to perform param: string The ID of the module param: string The parameters targeted for this module |
DoActionBase($name, $id, $params, $returnid='') X-Ref |
Pas de description |
CreateFieldsetStart( $id, $name, $legend_text='', $addtext='', $addtext_legend='' ) X-Ref |
Returns the xhtml equivalent of an fieldset and legend. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution (not really used yet, but might be later) param: string The html name of the textbox (not really used yet, but might be later on) param: string The legend_text for this fieldset, if applicaple param: string Any additional text that should be added into the tag when rendered param: string Any additional text that should be added into the legend tag when rendered |
CreateFieldsetEnd() X-Ref |
Returns the end of the fieldset in a form. This is basically just a wrapper around </form>, but could be extended later on down the road. It's here mainly for consistency. |
CreateFrontendFormStart($id,$returnid,$action='default',$method='post',$enctype='',$inline=true,$idsuffix='',$params=array() X-Ref |
Returns the start of a module form, optimized for frontend use param: string The id given to the module on execution param: string The id to eventually return to when the module is finished it's task param: string The action that this form should do when the form is submitted param: string Method to use for the form tag. Defaults to 'post' param: string Optional enctype to use, Good for situations where files are being uploaded param: boolean A flag to determine if actions should be handled inline (no moduleinterface.php -- only works for frontend) param: string Text to append to the end of the id and name of the form param: array Extra parameters to pass along when the form is submitted |
CreateFormStart($id, $action='default', $returnid='', $method='post', $enctype='', $inline=false, $idsuffix='', $params = array() X-Ref |
Returns the start of a module form param: string The id given to the module on execution param: string The action that this form should do when the form is submitted param: string The id to eventually return to when the module is finished it's task param: string Method to use for the form tag. Defaults to 'post' param: string Optional enctype to use, Good for situations where files are being uploaded param: boolean A flag to determine if actions should be handled inline (no moduleinterface.php -- only works for frontend) param: string Text to append to the end of the id and name of the form param: array Extra parameters to pass along when the form is submitted param: string Text to append to the <form>-statement, for instanse for javascript-validation code |
CreateFormEnd() X-Ref |
Returns the end of the a module form. This is basically just a wrapper around </form>, but could be extended later on down the road. It's here mainly for consistency. |
CreateInputText($id, $name, $value='', $size='10', $maxlength='255', $addttext='') X-Ref |
Returns the xhtml equivalent of an input textbox. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the textbox param: string The predefined value of the textbox, if any param: string The number of columns wide the textbox should be displayed param: string The maximum number of characters that should be allowed to be entered param: string Any additional text that should be added into the tag when rendered |
CreateLabelForInput($id, $name, $labeltext='', $addttext='') X-Ref |
Returns the xhtml equivalent of an label for input field. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the input field this label is associated to param: string The text in the label param: string Any additional text that should be added into the tag when rendered |
CreateInputTextWithLabel($id, $name, $value='', $size='10', $maxlength='255', $addttext='', $label='', $labeladdtext='') X-Ref |
Returns the xhtml equivalent of an input textbox with label. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the textbox param: string The predefined value of the textbox, if any param: string The number of columns wide the textbox should be displayed param: string The maximum number of characters that should be allowed to be entered param: string Any additional text that should be added into the tag when rendered param: string The text for label param: string Any additional text that should be added into the tag when rendered |
CreateInputFile($id, $name, $accept='', $size='10',$addttext='') X-Ref |
Returns the xhtml equivalent of a file-selector field. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the textbox param: string The MIME-type to be accepted, default is all param: string The number of columns wide the textbox should be displayed param: string Any additional text that should be added into the tag when rendered |
CreateInputPassword($id, $name, $value='', $size='10', $maxlength='255', $addttext='') X-Ref |
Returns the xhtml equivalent of an input password-box. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the textbox param: string The predefined value of the textbox, if any param: string The number of columns wide the textbox should be displayed param: string The maximum number of characters that should be allowed to be entered param: string Any additional text that should be added into the tag when rendered |
CreateInputHidden($id, $name, $value='', $addttext='') X-Ref |
Returns the xhtml equivalent of a hidden field. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the hidden field param: string The predefined value of the field, if any param: string Any additional text that should be added into the tag when rendered |
CreateInputCheckbox($id, $name, $value='', $selectedvalue='', $addttext='') X-Ref |
Returns the xhtml equivalent of a checkbox. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the checkbox param: string The predefined value of the field, if any param: string Any additional text that should be added into the tag when rendered |
CreateInputSubmit($id, $name, $value='', $addttext='', $image='', $confirmtext='') X-Ref |
Returns the xhtml equivalent of a submit button. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the button param: string The predefined value of the button, if any param: string Any additional text that should be added into the tag when rendered param: string Use an image instead of a regular button |
CreateInputReset($id, $name, $value='Reset', $addttext='') X-Ref |
Returns the xhtml equivalent of a reset button. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the button param: string The predefined value of the button, if any param: string Any additional text that should be added into the tag when rendered |
CreateFileUploadInput($id, $name, $addttext='') X-Ref |
Returns the xhtml equivalent of a file upload input. This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The html name of the input param: string Any additional text that should be added into the tag when rendered |
CreateInputDropdown($id, $name, $items, $selectedindex=-1, $selectedvalue='', $addttext='') X-Ref |
Returns the xhtml equivalent of a dropdown list. This is basically a nice little wrapper to make sure that id's are placed in names and also that it is xhtml compliant. param: string The id given to the module on execution param: string The html name of the dropdown list param: string An array of items to put into the dropdown list... they should be $key=>$value pairs param: string The default selected index of the dropdown list. Setting to -1 will result in the first choice being selected param: string The default selected value of the dropdown list. Setting to '' will result in the first choice being selected param: string Any additional text that should be added into the tag when rendered |
CreateInputSelectList($id, $name, $items, $selecteditems=array() X-Ref |
Returns the xhtml equivalent of a multi-select list. This is basically a nice little wrapper to make sure that id's are placed in names and also that it is xhtml compliant. param: string The id given to the module on execution param: string The html name of the select list param: string An array of items to put into the list... they should be $key=>$value pairs param: string An array of items in the list that should default to selected. param: string The number of rows to be visible in the list (before scrolling). param: string Any additional text that should be added into the tag when rendered param: boolean indicates wether multiple selections are allowed (defaults to true) |
CreateInputRadioGroup($id, $name, $items, $selectedvalue='', $addttext='', $delimiter='') X-Ref |
Returns the xhtml equivalent of a set of radio buttons. This is basically a nice little wrapper to make sure that id's are placed in names and also that it is xhtml compliant. param: string The id given to the module on execution param: string The html name of the radio group param: string An array of items to create as radio buttons... they should be $key=>$value pairs param: string The default selected index of the radio group. Setting to -1 will result in the first choice being selected param: string Any additional text that should be added into the tag when rendered param: string A delimiter to throw between each radio button, e.g., a <br /> tag or something for formatting |
CreateTextArea($enablewysiwyg, $id, $text, $name, $classname='', $htmlid='', $encoding='', $stylesheet='', $width='80', $cols='15',$forcewysiwyg="") X-Ref |
Returns the xhtml equivalent of a textarea. Also takes WYSIWYG preference into consideration if it's called from the admin side. param: bool Should we try to create a WYSIWYG for this textarea? param: string The id given to the module on execution param: string The text to display in the textarea's content param: string The html name of the textarea param: string The CSS class to associate this textarea to param: string The html id to give to this textarea param: string The encoding to use for the content param: string The text of the stylesheet associated to this content. Only used for certain WYSIWYGs param: string The number of characters wide (columns) the resulting textarea should be param: string The number of characters high (rows) the resulting textarea should be param: string The wysiwyg-system to be forced even if the user has chosen another one |
CreateFrontendLink( $id, $returnid, $action, $contents='', $params=array() X-Ref |
Returns the xhtml equivalent of an href link This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The id to eventually return to when the module is finished it's task param: string The action that this form should do when the link is clicked param: string The text that will have to be clicked to follow the link param: string An array of params that should be inlucded in the URL of the link. These should be in a $key=>$value format. param: string Text to display in a javascript warning box. If they click no, the link is not followed by the browser. param: boolean A flag to determine if only the href section should be returned param: boolean A flag to determine if actions should be handled inline (no moduleinterface.php -- only works for frontend) param: string Any additional text that should be added into the tag when rendered |
CreateLink($id, $action, $returnid='', $contents='', $params=array() X-Ref |
Returns the xhtml equivalent of an href link This is basically a nice little wrapper to make sure that id's are placed in names and also that it's xhtml compliant. param: string The id given to the module on execution param: string The action that this form should do when the link is clicked param: string The id to eventually return to when the module is finished it's task param: string The text that will have to be clicked to follow the link param: string An array of params that should be inlucded in the URL of the link. These should be in a $key=>$value format. param: string Text to display in a javascript warning box. If they click no, the link is not followed by the browser. param: boolean A flag to determine if only the href section should be returned param: boolean A flag to determine if actions should be handled inline (no moduleinterface.php -- only works for frontend) param: string Any additional text that should be added into the tag when rendered |
CreateContentLink($pageid, $contents='') X-Ref |
Returns the xhtml equivalent of an href link for content links. This is basically a nice little wrapper to make sure that we go back to where we want and that it's xhtml complient param: string the page id of the page we want to direct to |
CreateReturnLink($id, $returnid, $contents='', $params=array() X-Ref |
Returns the xhtml equivalent of an href link for Content links. This is basically a nice little wrapper to make sure that we go back to where we want to and that it's xhtml compliant. param: string The id given to the module on execution param: string The id to return to when the module is finished it's task param: string The text that will have to be clicked to follow the link param: string An array of params that should be inlucded in the URL of the link. These should be in a $key=>$value format. param: boolean A flag to determine if only the href section should be returned |
RedirectForFrontEnd($id, $returnid, $action, $params = array() X-Ref |
Redirects the user to another action of the module. This function is optimized for frontend use. param: string The id given to the module on execution param: string The action that this form should do when the form is submitted param: string The id to eventually return to when the module is finished it's task param: string An array of params that should be inlucded in the URL of the link. These should be in a $key=>$value format. param: boolean A flag to determine if actions should be handled inline (no moduleinterface.php -- only works for frontend) |
Redirect($id, $action, $returnid='', $params=array() X-Ref |
Redirects the user to another action of the module. param: string The id given to the module on execution param: string The action that this form should do when the form is submitted param: string The id to eventually return to when the module is finished it's task param: string An array of params that should be inlucded in the URL of the link. These should be in a $key=>$value format. param: boolean A flag to determine if actions should be handled inline (no moduleinterface.php -- only works for frontend) |
RedirectContent($id) X-Ref |
Redirects the user to a content page outside of the module. The passed around returnid is frequently used for this so that the user will return back to the page from which they first entered the module. param: string Content id to redirect to. |
GetModuleInstance($module) X-Ref |
------------------------------------------------------------------ Intermodule Functions ------------------------------------------------------------------ |
DefaultLanguage() X-Ref |
Sets the default language (usually en_US) for the module. There should be at least a language file for this language if the Lang() function is used at all. |
Lang() X-Ref |
Returns the corresponding translated string for the id given. param: string Id of the string to lookup and return param: array Corresponding params for string that require replacement. |
ListTemplates($modulename = '') X-Ref |
------------------------------------------------------------------ Template/Smarty Functions ------------------------------------------------------------------ |
GetTemplate($tpl_name, $modulename = '') X-Ref |
Returns a database saved template. This should be used for admin functions only, as it doesn't follow any smarty caching rules. |
GetTemplateFromFile($template_name) X-Ref |
Returns contents of the template that resides in modules/ModuleName/templates/{template_name}.tpl Code adapted from the Guestbook module |
SetTemplate($tpl_name, $content, $modulename = '') X-Ref |
Pas de description |
DeleteTemplate($tpl_name = '', $modulename = '') X-Ref |
Pas de description |
IsFileTemplateCached($tpl_name, $designation = '', $timestamp = '', $cacheid = '') X-Ref |
Pas de description |
ProcessTemplate($tpl_name, $designation = '', $cache = false, $cacheid = '') X-Ref |
Pas de description |
IsDatabaseTemplateCached($tpl_name, $designation = '', $timestamp = '') X-Ref |
Pas de description |
ProcessTemplateFromData( $data ) X-Ref |
Given a template in a variable, this method processes it through smarty note, there is no caching involved. |
ProcessTemplateFromDatabase($tpl_name, $designation = '', $cache = false) X-Ref |
Pas de description |
ListUserTags() X-Ref |
Pas de description |
CallUserTag($name, $params = array() X-Ref |
Pas de description |
StartTabHeaders() X-Ref |
------------------------------------------------------------------ Tab Functions ------------------------------------------------------------------ |
SetTabHeader($tabid,$title,$active=false) X-Ref |
Pas de description |
EndTabHeaders() X-Ref |
Pas de description |
StartTabContent() X-Ref |
Pas de description |
EndTabContent() X-Ref |
Pas de description |
StartTab($tabid, $params = array() X-Ref |
Pas de description |
EndTab() X-Ref |
Pas de description |
AdminStyle() X-Ref |
Module can spit out extra CSS for the admin side |
SetContentType($contenttype) X-Ref |
Set the content-type header. param: string Value to set the content-type header too |
Audit($itemid, $itemname, $action) X-Ref |
Put an event into the audit (admin) log. This should be done on most admin events for consistency. |
CreatePermission($permission_name, $permission_text) X-Ref |
Create's a new permission for use by the module. param: string Name of the permission to create param: string Description of the permission |
CheckPermission($permission_name) X-Ref |
Checks a permission against the currently logged in user. param: string The name of the permission to check against the current user |
RemovePermission($permission_name) X-Ref |
Removes a permission from the system. If recreated, the permission would have to be set to all groups again. param: string The name of the permission to remove |
GetPreference($preference_name, $defaultvalue='') X-Ref |
Returns a module preference if it exists. param: string The name of the preference to check param: string The default value, just in case it doesn't exist |
SetPreference($preference_name, $value) X-Ref |
Sets a module preference. param: string The name of the preference to set param: string The value to set it to |
RemovePreference($preference_name='') X-Ref |
Removes a module preference. If no preference name is specified, removes all module preferences. param: string The name of the preference to remove |
CreatePagination($id, $action, $returnid, $page, $totalrows, $limit, $inline=false) X-Ref |
Creates a string containing links to all the pages. param: string The id given to the module on execution param: string The action that this form should do when the form is submitted param: string The id to eventually return to when the module is finished it's task param: string the current page to display param: string the amount of items being listed param: string the amount of items to list per page param: boolean A flag to determine if actions should be handled inline (no moduleinterface.php -- only works for frontend) |
ShowMessage($message) X-Ref |
ShowMessage Returns a formatted page status message param: message - Message to be shown |
ShowErrors($errors) X-Ref |
ShowErrors Outputs errors in a nice error box with a troubleshooting link to the wiki param: errors - array or string of errors to be shown |
AddEventHandler( $modulename, $eventname, $removable = true ) X-Ref |
Add an event handler for a module event returns: mixed If successful, true. If it fails, false. param: string $modulename The name of the module sending the event param: string $eventname The name of the event param: boolean $removable Can this event be removed from the list? |
CreateEvent( $eventname ) X-Ref |
Inform the system about a new event that can be generated returns: nothing param: string The name of the event |
DoEvent( $originator, $eventname, &$params ) X-Ref |
Handle an event triggered by another module This method must be over-ridden if this module is capable of handling events. of any type. returns: boolean param: string The name of the originating module param: string The name of the event param: array Array of parameters provided with the event. |
GetEventDescription( $eventname ) X-Ref |
Get a (langified) description for an event this module created. This method must be over-ridden if this module created any events. returns: text string param: string The name of the event |
GetEventHelp( $eventname ) X-Ref |
Get a (langified) descriptionof the details about when an event is created, and the parameters that are attached with it. This method must be over-ridden if this module created any events. param: string The name of the event |
HandlesEvents() X-Ref |
A callback indicating if this module has a DoEvent method to handle incoming events. |
RemoveEvent( $eventname ) X-Ref |
Remove an event from the CMS system This function removes all handlers to the event, and completely removes all references to this event from the database Note, only events created by this module can be removed. returns: nothing param: string The name of the event |
RemoveEventHandler( $modulename, $eventname ) X-Ref |
Remove an event from the CMS system This function removes all handlers to the event, and completely removes all references to this event from the database Note, only events created by this module can be removed. returns: nothing param: string The name of the event |
SendEvent( $eventname, $params ) X-Ref |
Trigger an event. This function will call all registered event handlers for the event returns: nothing param: string The name of the event param: array The parameters associated with this event. |
Généré le : Tue Apr 3 18:50:37 2007 | par Balluche grâce à PHPXref 0.7 |