Creating a array of multiple form input's ids and values using jquery?

You could try sending your ajax request in a more PHP friendly manner. For instance this: $. Ajax({ url : 'yourdomain.com', data : { 'item1' : 'one', 'item2' : 'two', 'item3' : 'three' } }) will send a request like this: http://yourdomain.com/?

Item1=one&item2=two&item3=three and the data will be available in the PHP var $_GET'item' which you can loop through like this: foreach($_GET'item' as $id => $value) { // insert, etc.. }.

You could try sending your ajax request in a more PHP friendly manner. For instance this: $. Ajax({ url : 'yourdomain.com', data : { 'item1' : 'one', 'item2' : 'two', 'item3' : 'three' } }); will send a request like this: http://yourdomain.com/?

Item1=one&item2=two&item3=three and the data will be available in the PHP var $_GET'item' which you can loop through like this: foreach($_GET'item' as $id => $value) { // insert, etc.. }.

Michael Merchant is totally right that you should probably use { 'type' : 'post' } in your ajax call to send a POST instead of a GET request, since you mention that you'll be modifying a database. However, the result in PHP will be in the variable $_POST'item' not $_POST'item1' – owise1 Sep 15 '10 at 15:54.

If you're trying to make a POST request and for whatever reason, it matters for you to not send a GET request (for example, you're modifying information stored on the server), you may want to use: $. Ajax({ url : 'yourdomain.com', data : { 'item1' : 'one', 'item2' : 'two', 'item3' : 'three' }, type: "POST", }); You can then access the data on your server from the $_POST dictionary by calling: $_POST'item1'.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions