I have an external script located in the WP directory. I want to protect this from everyone except the admin. I was wondering if there was a way to do this. Maybe through WP cookies?
The script is very simple. I just want to include something that requires the admin to be logged in. When logged in, they can access the directory as normal.