public static
boolean|string
|
#
toDate( $timestamp )
Converts timestamp to WP Date format set in general settings
Converts timestamp to WP Date format set in general settings
Parameters
Returns
boolean|string
Since
2.0
|
public static
boolean|string
|
#
toDateTime( $timestamp )
Converts timestamp to WP Date and Time format
which is set in general settings
Converts timestamp to WP Date and Time format
which is set in general settings
Parameters
Returns
boolean|string
Since
2.0
|
public static
|
#
setTimezone( )
Execute to set timezone before using any date related functions.
Execute to set timezone before using any date related functions.
Since
2.0
|
public static
boolean
|
#
register_update_hook( string $file, callable $callback, boolean|string $version = false )
Register a routine to be called when a plugin has been updated
Register a routine to be called when a plugin has been updated
It works by comparing the current version with the version previously stored in the database.
Parameters
- $file
- A reference to the main plugin file
- $callback
- The function to run when the hook is called.
- $version
- The version to which the plugin is updating.
Returns
boolean
Since
2.0
Source
https://core.trac.wordpress.org/attachment/ticket/14912/plugin-versions.4.diff
|
public static
|
#
registerPluginVersion( $file )
Run on init action to make sure it's executed after
register_update_hook
Run on init action to make sure it's executed after
register_update_hook
|
public static
string
|
#
getCurrentUrl( )
Returns current URL loaded in the browser
Returns current URL loaded in the browser
Returns
string
|