Problem with ajax using jquery when sending data to php
I am having a weird problem sending data to php using ajax with JQuery
here is my code:
JavaScript
Solution:Jump to solution
Can you not edit this? You are converting it to a string here
newChkStates = '"{' + newChkStates.slice(0, -1) + '}"';
...6 Replies
Here are the errors I am getting from the php
The error is refering to the php part where I used
echo sizeof($newChkStates);
I need it to be converted to associative array instead of a string.Here is the value of newChkStates in the console when I
console.log
ed itSolution
Can you not edit this? You are converting it to a string here
newChkStates = '"{' + newChkStates.slice(0, -1) + '}"';
Or maybe I am reading too far and the error happens earlier
You are absolutely right. That was the problem that kept my brain hurt for 2 days. Thanks a lot for the help