If the constant named 'WP_SITEURL' is defined, then the value in that constant will always be returned. This can be used for debugging a site on your localhost while not having to change the database to your URL.
Parameters
$urlstringoptional
URL to set the WordPress site location.Default: ''
Return
string
The WordPress site URL.
Uses · 1
untrailingslashit()Removes trailing forward slashes and backslashes if they exist.
Signature, return type and hooks compared across 5 parsed releases.
About this page
Parsed data
Generated from the wordpress-develop 7.0.4 tag, from src/wp-includes/functions.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
Corrections
Something wrong on this page? Report it and it gets fixed in the next regeneration.