List of All Global Variables
_is_draft
Check if the page is hidden (as indicated by a double underscore in the filename)
_is_hidden
Check if the page is hidden (as indicated by a single underscore in the filename)
current_date
Display the current server date/time formatted by your _date_format
setting. Accepts the format
parameter.
current_url
The URL of your current page. Example: /about/team
environment
The name of your current environment if set.
homepage
The URL to your homepage. Example: /
.
is_admin
Returns TRUE if the user is logged in with admin privileges.
is_{environment_name}
Where "{environment_name}" is the name of the environment you wish to check for. Useful in conditions. Example if is_dev.
last_modified
The last modified timestamp of the current page/entry. Accepts the format
parameter.
last_segment
The last segment in your URL.
logged_in
returns TRUE/FALSE on whether the current user is logged in.
next
If on an entry page, the URL to the next entry.
now
The current timestamp, as in "right now"
page_url
The URL of your current page. Example: /about/team
permalink
The fully qualified URL of your current page. Example: http://example.com/about/team
prev
If on an entry page, the URL to the previous entry.
segment_x
Where "x" is any segment number. Returns the value of any given URL segment if present. Example: with a URL of /about/team/jack-london, segment_2
would return team.
taxonomy_name
If on a taxonomy URL returns the taxonomy name.
taxonomy_slug
If on a taxonomy URL returns the URL slug containing the taxonomy name.
theme_path
Path to your current theme: Example: _themes/denali/
username
If logged in, the username of the current user.