I am trying to use get_page() in a page template file to grab the slug, like so:
$slug = get_page()->post_name;
but I am getting the warning:
PHP Warning: Missing argument 1 for get_page(), called in .../profiles-page.php on line 24 and defined in .../wp-includes/post.php on line 3110
According to the Codex page, any parameters are optional. Anybody have any ideas about why I am getting this error?