CodeIgniter Forums
Retrieving POST data works on localhost but not on server - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Retrieving POST data works on localhost but not on server (/showthread.php?tid=44975)



Retrieving POST data works on localhost but not on server - El Forum - 09-02-2011

[eluser]Unknown[/eluser]
Hello,

This is driving me nuts!

A very simple Contact Us form. It takes a name, email, and message, and then posts to a method which emails the site admin this data. Everything works fine through XAMPP but when I upload it to my server I cannot retrieve POST data.

No javascript is being used. I had read that it would not hurt to validate the post data through use of form_validation which I am now doing. I have found that it is failing validation, probably because it is NULL(?!?)

I am attempting to retrieve the data with the following code:

Code:
$name = $this->input->post('name');
$email = $this->input->post('email');
$message = $this->input->post('message');


I have made sure that it is not a URL issue.

Does anyone have any thoughts? Is this an issue with my host? They are running PHP 5.3.6 and APACHE 2.2.18.

I would appreciate any help!

Chad