Welcome Guest, Not a member yet? Register   Sign In
Date string encoding, Config Issue?
#1

[eluser]novice32[/eluser]
Hello,

This works in localhost (XAMPP / Windows) but not in production (CentOS Linux).

In the application GUI I enter "04/09/2010" which is sent via POST as string "ItemFoundDate=04/09/2010". However, in the controller the below assignment throws an 500 error.
Code:
$ItemFoundDate =  date("Y-m-d", strtotime($this->input->post('ItemFoundDate')));
I was pre-formatting for a MySQL insert. Anyhow, just to ensure "strtotime" has nothing to do with the issue, I tried the below this still causes an error.
Code:
$ItemFoundDate =  $this->input->post('ItemFoundDate');

Could this be a config setting?

Please advise.
Novice32


Messages In This Thread
Date string encoding, Config Issue? - by El Forum - 04-08-2010, 10:50 PM
Date string encoding, Config Issue? - by El Forum - 04-09-2010, 05:59 AM
Date string encoding, Config Issue? - by El Forum - 04-09-2010, 04:03 PM



Theme © iAndrew 2016 - Forum software by © MyBB