I'm working with JSON string (array data) coming from AJAX.
Until now, it's working. But last few days, I receive apparently from Ukraine (ip analyse) JSON array with 'data:null'.
Is it possible to code a condition before insert in database with an error message?
Currently I am checking with:
if($item[0]['data1'] !=Null || $item[0]['data1'] !='')
{ insert request }
and the same for the other array data
Is it correct ?