## Current path on page in functions.php

Question

How can I get the current path of my page?

I know how to do it inside a template file, but I need it inside functions.php.
And it has to be before the send_headers hook, because I’ll use this info to set a cookie.

I tried using PHP, but I’m getting /wp-admin

0
2 years 2020-01-09T08:40:11-05:00 0 Answers 88 views 0