php, form, post, and response
-
Hi
I need to create a form that posts to a .php file, i.e.
<form method=”post” action=”/foo.php”>
</form>The page with this form itself contains some php code. Now, I’ve installed the exec-php plugin and I’m able to create a wordpress page that generates the form. I’m also able to post to /foo.php and have it do some processing and output the result I need. So far so good.
However, I want foo.php itself to look like a wordpress page so it blends in with the rest of my blog. I guess ideally, I want to create a wordpress page with php code, and have that page NOT published by default but just sitting there. Then when it’s called the output will be embedded inside the normal blog.
Just in case that’s not clear, let’s say foo.php contains just this
<?php
echo “hello world”
?>Right now, when I call it, I get a page that just says ‘hello world’
I want to have a page that looks like a regular wordpress page with all my header, footer, sidebar, widgets, etc., and says ‘hello world’, and I don’t want this page to be visible (no link on top) until it’s invoked via a form post from another page. How can I do that?
Thanks very much in advance.
- The topic ‘php, form, post, and response’ is closed to new replies.