Login | Register | FAQ
Anonymous

Ajax Question...(jquery .ajax())

+ Post a reply

4 posts Page 1 of 1


Ajax Question...(jquery .ajax())

by soccerwebsitemaker » Thu Jun 07, 2012 1:44 am

So, I'm practicing my .ajax() skills (on reference from XainPro in PHP forum) and I am wondering how to retrieve the content on the PHP page that it gets sent to.

For example, I send data with jQuery AJAX...then I stuff it into database, but how do I put it in the database? How do I get hold of the data?
User avatar

soccerwebsitemaker

  • Posts: 139
  • Joined: Sat Dec 31, 2011 6:25 pm
--
Coins. Profile. Games. Chat. Fun.

CoinAwards.

Check it out at http://www.coinawards.net63.net/

Re: Ajax Question...(jquery .ajax())

by XainPro » Thu Jun 07, 2012 7:46 am

just like normal way use $_POST or $_GET
User avatar

XainPro

  • Posts: 3567
  • Joined: Fri Feb 17, 2012 8:10 pm

Re: Ajax Question...(jquery .ajax())

by soccerwebsitemaker » Thu Jun 07, 2012 8:52 pm

So I just do...

$_POST["seebelow"];

What do I put there?

Do I put the name of the element that has the onclick attribute that performs the ajax function?

For example - <input type="radio" name="radioBTN" onclick="ajax()" />

PHP:

$_POST["radioBTN"];





Does this work...?
User avatar

soccerwebsitemaker

  • Posts: 139
  • Joined: Sat Dec 31, 2011 6:25 pm
--
Coins. Profile. Games. Chat. Fun.

CoinAwards.

Check it out at http://www.coinawards.net63.net/

Re: Ajax Question...(jquery .ajax())

by XainPro » Fri Jun 08, 2012 11:09 am

yes but ajax() should be a function which perform the ajax activity like sending form through the help of java scrip.
User avatar

XainPro

  • Posts: 3567
  • Joined: Fri Feb 17, 2012 8:10 pm


+ Post a reply

Page 1 of 1

?>