Jump to content

Contact form not returning content. Please help.


gbetza
 Share

Recommended Posts

I've been working with php for a short time and picked this form up online to use for my contact page. When tested on my server, http://www.d1082919....h/contact2.html the text fields return all of the correct content (email, name, phone, etc.) to me in an email. When I put the site live, http://vitalhabitats.com/contact2.html the text fields all return blank. I still receive the email, but it looks like this: Email:Name:Phone Number:Comments:Newsletter: I cannot understand what the potential issue may be. I know the form works, just not on this server. My php file is attached for review. Any help is greatly appreciated.

contactformprocess.php

Link to comment
Share on other sites

you could try $_REQUEST array:

$emailField = $_REQUEST['email'];$nameField = $_REQUEST['name'];$phoneField = $_REQUEST['phone'];$commentsField = $_REQUEST['comments'];$newsletterField = $_REQUEST['newsletter'];

or dumping $_POST/$_REQUEST array:

print_r($_POST);print_r($_REQUEST);

to see if there's some data.. (maybe a php conf problem...)

Edited by viper_
Link to comment
Share on other sites

you could try $_REQUEST array:
$emailField = $_REQUEST['email'];$nameField = $_REQUEST['name'];$phoneField = $_REQUEST['phone'];$commentsField = $_REQUEST['comments'];$newsletterField = $_REQUEST['newsletter'];

or dumping $_POST/$_REQUEST array:

print_r($_POST);print_r($_REQUEST);

to see if there's some data.. (maybe a php conf problem...)

Thanks viper_. I tried the $_REQUEST array and it works but it doesn't solve the issue. My fields are still returning blank. As for dumping the $_POST/$_REQUEST array, I'm not sure what you mean. I'm really pretty new to this so if you could elaborate that would help. I look forward to your reply.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...