This page is a work in progress.
Signature
getXML($path_to_file)
Description
Retrieves the XML contents from $path_to_file
and returns it as a SimpleXMLExtended object.
Signature
XMLsave($xml, $file)
Description
Saves (ideally SimpleXMLExtended) $xml
objects to the $file
path.
If GSFORMATXML
is true, will pretty-print the XML string.
This function executes the filter xmlsave
every time it is called, so that everyone can alter the XML string by using add_filter('xmlsave', 'myFunc')
Signature
lngDate($date)
Description
Returns a date according to the format stored in the global $i18n
keyDATE_AND_TIME_FORMAT
, in admin/lang/
.
Default format is F jS, Y - g:i A
, see PHP dates and times.
Signature
shtDate($date)
Description
Returns a date according to the format stored in the global $i18n
keyDATE_FORMAT
, in admin/lang/
.
Default format is M j, Y
, see PHP dates and times.
Signature
cl($data)
Description
Cleans $data
consecutively with html_entity_decode, strip_tags and strip_slashes
Parameters
$data
, the data string to cleanSignature
tsl($path)
Description
Adds a trailing slash to $path
if there isn't one yet.
Parameters
$path
, the path to add a trailing slash to.Signature
strippath($path_to_file)
Description
Returns the filename and extension from $path_to_file
, using pathinfo
.
Signature
strip_quotes($text)
Description
Strips HTML entity quotes, double and single quotes from $text
and returns the result.
Parameters
$text
, the string to strip quotes fromSignature
encode_quotes($text)
Description
Encodes quotes as HTML entities with htmlspecialchars
and trims whitespace in $text
.
Parameters
$text
, the text to encode quotes in.Signature
i18n($key[, $echo=true])
Description
Outputs the translation of $key
in the global $i18n
(in the current language, or en_US if it does not exist), or returns it if $echo
is false.
Parameters
$key
, the key of the translation to find$echo
(optional), whether to echo or return the value. If $echo
is false, acts the same as i18n_r
Signature
i18n_r($key)
Description
Shorthand for i18n($key, true)
. Returns the translation for $key
.
Signature
i18n_merge($plugin[, $language=null])
Description
Merges a plugin's language file with the global $i18n
language.
Parameters
$plugin
, the namespace of the plugin's language.$language
(optional), don't pass unless you want to force a specific language.Signature
i18n_merge_impl($plugin, $lang, &$globali18n)
Description
Used by i18n_merge
to do the actual merging of the plugin's i18n namespace (in the plugin's lang folder) with the global $i18n
variable.
Signature
lowercase($text)
Description
Converts $text
to lowercase.
Signature
find_accesskey($i18n_string)
Description
Relies on access keys being enclosed by '<em></em>' elements in an i18n string. Used especially in the admin's main navigation.