If the keys of your array are integers, try using unset() on the array and then use array_splice() to renumber the keys.
For example:
$test[0] = '5';
$test[1] = '6';
$test[2] = '7';
$test[3] = '8';
$test[4] = '9';
unset($test[2]);
array_splice($test,0,0);
for($i=0; $i<count($test); $i++) {...
Did the string use to work with the database before? If it did, you can always use stripslashes() to undo what you did with addslashes() before querying the database.
Could you provide more information on the problem, like what error messages are you getting if any? What you are trying to...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.