• Let me first explain my situation here, because quite honestly the only confusing aspect with regards to what I’m trying to accomplish is WordPress itself. I am writing within a plugin file which displays its code through a custom WordPress page I made (domain.com/my-page). When I go to domain.com/my-page I’m displayed with a form – one that I created in the plugin file – and I would like to be able to send $_POST data from that form, and receive it on the same page. I’m beginning to think that this is not possible, because when I post to the same WordPress page, the $_POST data is not being found/returned. I began to think that perhaps I should be posting to the headers.php file instead; however, two questions arose:

    1. How can I post to the headers.php file -> Is there a built-in wordpress variable for finding the header.php file?
    2. If $_POST data is received by the headers.php file, how can I then get this information back to the page that I was working on?

  • The topic ‘Sending $_POST data to headers.php from plugin file’ is closed to new replies.