Méthode |
Description |
|
action_admin_init_check_plugin_dependencies ( ) |
Checks if environment variable depencies are available on the server |
|
action_admin_notices ( ) |
Displays notice in the admin area if the dependent environment variables are not present |
|
action_init_register_shortcodes ( ) : null |
Register the shortcode(s) |
|
city ( ) : mixed |
Get City |
|
compare_location_type ( $a, $b ) |
Compare the location types |
|
continent ( $country = '' ) : string |
Get Continent |
|
country ( ) : string |
Get Country |
|
distance_to ( $lat, $lng, $metric = false ) : float |
Utility function: Calculate distance to point |
|
do_shortcode_city ( $atts ) : string |
Output the current city |
|
do_shortcode_content ( $atts, $content = null ) : string |
Output the content filtered by region |
|
do_shortcode_continent ( $atts ) : string |
Output the current continent |
|
do_shortcode_country ( $atts ) : string |
Output the current country |
|
do_shortcode_latitude ( $atts ) : string |
Output the current latitude |
|
do_shortcode_location ( $atts ) : string |
Output the current human readable location, in a smart way. |
|
do_shortcode_longitude ( $atts ) : string |
Output the current longitude |
|
do_shortcode_postal_code ( $atts ) : string |
Output the current postal code |
|
do_shortcode_region ( $atts ) : string |
Output the current region |
|
get_actuals ( ) : array |
Here we extract the data from headers set by nginx -- lets only send them if they are part of the cache key |
|
get_test_parameters ( $geos ) : array |
We want people to be able to test the plugin, so we'll include some url parameters that will spoof a location |
|
init ( ) |
Initialize hooks and setup environment variables |
|
instance ( ) |
Register singleton |
|
latitude ( ) : mixed |
Get Latitude |
|
longitude ( ) : mixed |
Get Longitude |
|
postal_code ( ) : mixed |
Get Postal Code |
|
region ( ) : string |
Get Region |
|
setup ( ) |
Setup environment variables |
|