sp_PostEditorWindow

Important Note:  The contents of this document applies ONLY to version 5.x.x of Simple:Press.  It likely does NOT apply to version 6.x.x (our latest version).

Description

sp_PostEditorWindow() – A placeholder for the new post editor window. This function is placed where you want the post editor to be displayed when creating a new post or replying to a topic.

Usage

sp_PostEditorWindow($addPostForm, $editPostForm)

Arguments

$addPostForm

‘tagClass’  => ‘spForm’: CSS Class for the form
‘hide’    => 1: To hide form until new post is clicked or to display always. A zero would display the form.
‘controlFieldset’  => ‘spEditorFieldset’: CSS class for the fieldset
‘controlInput’  => ‘spControl’: CSS class for the input
‘controlSubmit’  => ‘spSubmit’: CSS class for the submit button.
‘labelHeading’  => __sp(‘Add Reply’): Label for reply button
‘labelGuestName’  => __sp(‘Guest name (required)’): Label
‘labelGuestEmail’  => __sp(‘Guest email (required)’): Label
‘labelModerateAll’   => __sp(‘NOTE: new posts are subject to administrator approval before being displayed’): Label/text shown if post requires approval
‘labelModerateOnce’   => __sp(‘NOTE: first posts are subject to administrator approval before being displayed’): Label/Text shown if first posts require approval.
‘labelSmileys’ => __sp(‘Smileys’): Label for Smileys
‘labelOptions’  => __sp(‘Options’): Label for options.
‘labelOptionLock’ => __sp(‘Lock this topic’): Label for lock topic option.
‘labelOptionPin’  => __sp(‘Pin this post’): Label for Pin Post option.
‘labelOptionTime’  => __sp(‘Edit post timestamp’): Label for edit timestamp option.
‘labelMath’  => __sp(‘Math Required’): Label shown if math question displayed.
‘labelMathSum’  => __sp(‘What is the sum of’): Math Question text.
‘labelPostButtonReady’   => __sp(‘Submit Reply’): Label for Submit reply button.
‘labelPostButtonMath’ => __sp(‘Do Math To Save’): Label for save post if need to do math question.
‘labelPostCancel’  => __sp(‘Cancel’): Label on cancel post button.
‘tipSmileysButton’ => __sp(‘Open/Close to Add a Smiley’): Label on open/close smileys box if used.
‘tipOptionsButton’  => __sp(‘Open/Close to select Posting Options’): Label to open/close options box if used.
‘tipSubmitButton’   => __sp(‘Save the New Post’): Text on button to save post.
‘tipCancelButton’   => __sp(‘Cancel the New Post’): Text on button to cancel a new post.

$editPostForm

‘tagClass’  => ‘spForm’: CSS class for the edit post form.
‘controlFieldset’  => ‘spEditorFieldset’: CSS class for the fieldset
‘controlInput’ => ‘spControl’: CSS class for the edit button.
‘controlSubmit’ => ‘spSubmit’: CSS class for the submit button
‘labelHeading’  => __sp(‘Edit Post’): Label/text shown on the edit post button.
‘labelSmileys’  => __sp(‘Smileys’):Label/text shown on thesmileys button.
‘labelPostButton => __sp(‘Save Edited Post’),Label/text shown on the save edit post button.
‘labelPostCancel’  => __sp(‘Cancel’)Label/text shown on the cancel post button.
‘tipSmileysButton’ => __sp(‘Open/Close to Add a Smiley’): Label on open/close smileys box if used.
‘tipSubmitButton’  => __sp(‘Save the Edited Post’): Tooltip popup text shown when link hovered to save post.
‘tipCancelButton’  => __sp(‘Cancel the Post Edits’): Tooltip popup text shown when link hovered to cancel post.

Special Notes

The arguments for the function are held in an array at the top of the topic view php page – spTopicView.php. You can change the arguments by editing the array.

Examples

Display using the default arguments.

sp_PostEditorWindow($addPostForm, $editPostForm);

Actions and Hooks Used in Template Tag

  • None

Changelog

Since Version: 5.0

Posted in