Posts: 4,368
Threads: 101
Joined: Oct 2014
Reputation:
146
The Ajax validation should be in the JavaScript code.
Transferring data should be done using Json format.
If the Ajax put is sending Json and it's an Json array you can use json_decode()
on it then use php to validate the data.
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
Posts: 9
Threads: 2
Joined: Dec 2018
Reputation:
0
That is exactly what I am about to do. Make my own validation for ajax requests. Thanks.
Posts: 1,284
Threads: 65
Joined: Oct 2014
Reputation:
82
The validation helper only works with information that would be in the $_REQUEST global. PUT requests don't work that way, so yes, you would need to pull out your json/xml and validate manually through the validator.