|· Forum rules (under construction) · Portal||Help Search Members Calendar|
|Welcome Guest ( Log In | Register )||Resend Validation Email|
|Welcome to MPAM Rebooted Forums. We hope you enjoy your visit.|
You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free.
Join our community!
If you're already a member please log in to your account to access all of our features:
Posted: Oct 30 2008, 12:11 AM
Member No.: 981
Joined: 28-October 08
To anyone that can help,
I am using Apache and PHP 5.
I am new to this environment and think I am missing some sort of command for apache.
Basically I made a small HTML test document and in it has two forms. One for a Name, the other for any type of text information I type in. This information is then submitted to a PHP script.
The problem is when I press send the php document is opened as a text document in notepad. I did not save it as a .txt file, I saved it as a .php. I can open the document via internet explore by going typing the directory name directly but for some reason when the document is called from the HTML document it is opened as text.
Has anyone experienced this before and has fixed it?
The code is as follows:
<title>A Simple HTML Form</title>
<form action="send_simpleform.php" method="POST">
<input type="text" name="user"/></p>
<textarea name="message" rows="5" cols="40"></textarea></p>
<p><input type="submit" value="send"/></p>
echo "<p>Welcome <b>".$_POST["user"]."</b>!</p>";
echo "<p>Your message is: <br/><b>".$_POST["message]."</b></p>";
Thanks for your help.
Posted: Oct 30 2008, 08:08 AM
Member No.: 18
Joined: 16-April 05
Are you sure you did properly the part called "Configuring Apache to work with PHP" in the tutorial? Particularly the part where adding "AddType application/x-httpd-php .php" in php.ini.
Otherwise, does the problem occurs on other browser than MSIE? (Firefox, Opera...)