NewsFeaturesDownloadsDevelopmentSupportAbout Us

AdminAddBlogTemplateAction Class Reference
[Action]

Inherits BlogOwnerAdminAction.

List of all members.


Public Member Functions

 AdminAddBlogTemplateAction ($actionInfo, $request)
 validate ()
 _performUploadTemplate ()
 perform ()

Public Attributes

 $_op

Private Member Functions

 _addTemplateCode ($templateName)
 _performScanTemplateFolder ()

Detailed Description

Shows a form to add a new locale file

Definition at line 18 of file adminaddblogtemplateaction.class.php.


Member Function Documentation

AdminAddBlogTemplateAction._addTemplateCode ( templateName  )  [private]

AdminAddBlogTemplateAction._performScanTemplateFolder (  )  [private]

scans the templates folder looking for new files

Definition at line 172 of file adminaddblogtemplateaction.class.php.

References _addTemplateCode(), TemplateSetStorage.getBlogBaseTemplateFolder(), TemplateSets.getBlogTemplates(), and AdminAction.setCommonData().

Referenced by perform().

AdminAddBlogTemplateAction._performUploadTemplate (  ) 

AdminAddBlogTemplateAction.AdminAddBlogTemplateAction ( actionInfo,
request 
)

AdminAddBlogTemplateAction.perform (  ) 

Receives the HTTP request from the client as parameter, so that we can extract the parameters and perform our business logic.

The result of this will be a view, which will normally be the output of the processing we just did or for example an error view showing an error message. Once we have completed processing, the controller will call the getView() method to get the resulting view and send it back to the customer.

Returns:
Returns nothing

Reimplemented from Action.

Definition at line 207 of file adminaddblogtemplateaction.class.php.

References $blogs, $result, _performScanTemplateFolder(), _performUploadTemplate(), die, and AdminAction.saveSession().

AdminAddBlogTemplateAction.validate (  ) 

This method can be used for data validation and is always executed before perform(). If it returns 'true', execution will continue as normal. If it returns 'false', the process will be stopped and the current contents of the view will be returned. If the view is empty, an exception will be thrown.

As of pLog 1.0, it is not necessary to implement data validation code here and it is recommended to use the data validation framework (see methods Action.registerFieldValidator() and related) There is more information about the data validation framework in the wiki: http://wiki.plogworld.net/index.php/PLog_1.0/Forms_and_data_validation.

With the default code provided in the Action.validate() method, the callback method Action.validationErrorProcessing() will be called and after that, the view set via the Action.setValidationErrorView() will be used to generate the contents of the error message.

Returns:
Returns true if data is correct or false otherwise. See above for more details.

Reimplemented from Action.

Definition at line 34 of file adminaddblogtemplateaction.class.php.

References $config, Config.getConfig(), getValue(), and AdminAction.setCommonData().


Member Data Documentation

AdminAddBlogTemplateAction.$_op

Definition at line 21 of file adminaddblogtemplateaction.class.php.