Okay so it turned out to be that I was using the incorrect action name. I changed "init"
to "wp_loaded"
in add_action()
and that did the trick.
Okay so it turned out to be that I was using the incorrect action name. I changed "init"
to "wp_loaded"
in add_action()
and that did the trick.