Documentation

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
v1.5:functions [2012/07/11 05:18]
jacob Made the page
v1.5:functions [2014/02/21 01:12] (current)
quy Remove function from the function name
Line 29: Line 29:
 Returns the protocol being used to access the server ('​http'​ or '​https'​);​ Returns the protocol being used to access the server ('​http'​ or '​https'​);​
  
-==== function ​get_base_url($support_https) ====+==== get_base_url($support_https) ====
 This returns the base URL of the forum (i.e. what was set up in the configuration),​ and if $support_https is set to true, it will return it in HTTP or HTTPS, depending on how the page is accessed. This returns the base URL of the forum (i.e. what was set up in the configuration),​ and if $support_https is set to true, it will return it in HTTP or HTTPS, depending on how the page is accessed.
  
Line 35: Line 35:
 This sets $pun_user to the defaults for a guest. This sets $pun_user to the defaults for a guest.
  
-==== function ​forum_hmac($data,​ $key, $raw_output) ====+==== forum_hmac($data,​ $key, $raw_output) ====
 A hash function, no better description at this time A hash function, no better description at this time
  
Line 96: Line 96:
 </​code>​ </​code>​
  
-==== function ​paginate($num_pages,​ $cur_page, $link) ====+==== paginate($num_pages,​ $cur_page, $link) ====
 Generates the page links (i.e. page 1, page 2, next page, previous page, etc.) Generates the page links (i.e. page 1, page 2, next page, previous page, etc.)
  
-==== function ​message($message,​ $no_back_link) ====+==== message($message,​ $no_back_link) ====
 This displays a message to the user and stops the current script. If $no_back_link is left out, then a back link will be displayed. This displays a message to the user and stops the current script. If $no_back_link is left out, then a back link will be displayed.
  
-==== function ​format_time($timestamp,​ $date_only = false, $date_format = null, $time_format = null, $time_only = false, $no_text = false) ====+==== format_time($timestamp,​ $date_only = false, $date_format = null, $time_format = null, $time_only = false, $no_text = false) ====
 Formats the time for the user (depending on the user's formatting preferences). Formats the time for the user (depending on the user's formatting preferences).
  
Line 126: Line 126:
 Returns $str with all HTML stripped Returns $str with all HTML stripped
  
-==== function ​pun_htmlspecialchars_decode($str) ====+==== pun_htmlspecialchars_decode($str) ====
 No description at this time No description at this time