Core Function
View Source on Trac ↗ site_url()
site_url( mixed $path = '', mixed $scheme = null ) Retrieves the URL for the current site where WordPress application files
Parameters 1 required
| Name / Type | Description |
|---|---|
| $path string | Optional. Path relative to the site URL. Default empty. |
| (string | | null) $scheme Optional. Scheme to give the site URL context. See set_url_scheme(). Required |
Return Value
(string)
Site URL link with optional path appended.
Function Information
Since Version
3.0.0
Source File
wp-includes/link-template.php
Advertisement