sp_Signature

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_Signature() – Display a specified signature.

Usage

sp_Signature($args, $sig);

Arguments

$args – List of arguments for controlling display.
Type:
(string) (optional)
Default:
‘tagClass’ => ‘spSignature’
‘echo’ => 1

‘tagClass’: CSS Class for Div.
‘echo’: Flag to indicate whether to write out the generated html display code or just return the html display code. One (1) is true and causes the html display code to be written to the display. Zero (0) is false and causes the html display code to be returned instead of written out.

$sig – The User ID of the displayed signature.
Type:
(string) (optional)
Default:
None

Special Notes

In standard supplied Simple:Press themes this is used in the profile page (spProfileShow.php) but can be used elsewhere on a forum page.

Examples

Return a users signature using the user ID from the currently viewed profile.

$out.= sp_Signature('echo=0', $spProfileUser->signature);

Actions and Hooks Used in Template Tag

  • apply_filters(‘sph_Signature_args’, $a) – Allows modification of the arguments to the template tag. $a contains the parsed arguments.
  • apply_filters(‘sph_Signature’, $out, $a) – Allows modification of the display code just prior to being output/returned. $out will contain the html display code.

Changelog

Since Simple:Press version 5.0.

Codex page sync’d to code version 5.4.1.

Source Code

sp_signature() is located in simple-press/forum/content/sp-common-view-functions.php.

Posted in