File tree Expand file tree Collapse file tree 2 files changed +14
-6
lines changed
Expand file tree Collapse file tree 2 files changed +14
-6
lines changed Original file line number Diff line number Diff line change 22
33if ((isset ($ _SERVER ['HTTP_X_REQUESTED_WITH ' ]) && $ _SERVER ['HTTP_X_REQUESTED_WITH ' ] == 'XMLHttpRequest ' )) {
44 //var_dump($_POST);
5- print json_encode (array ("firstName " =>'its-true ' ));
6-
5+ print json_encode (array ("firstName " =>'its-true ' ));
6+ //$json_obj = json_decode($_POST['json']);
7+ //print $json_obj->firstName;
8+ }else {
9+ echo 'I got my eyes on you. ' ;
710}
811
912
Original file line number Diff line number Diff line change 3939 json : JSON . stringify ( { firstName : "Jose" , lastName : "Romaniello" } )
4040 }
4141 ) . pipe ( function ( p ) {
42- return "Saved " + p . firstName ;
42+ //return "Saved " + p.firstName;
43+ } ) ;
44+ post . done ( function ( r ) {
45+ alert ( r ) ;
4346 } ) ;
44-
45- post . done ( function ( r ) { alert ( r ) ; } ) ;
4647
4748} ) ;
4849</ script >
4950 </ head >
5051 < body >
51- < div > jQuery Resolved</ div >
52+ < div id ="mother-div ">
53+ jQuery Resolved
54+ http://joseoncode.com/2011/09/26/a-walkthrough-jquery-deferred-and-promise/
55+ http://www.erichynds.com/jquery/using-deferreds-in-jquery/
56+ </ div >
5257 </ body >
5358</ html >
You can’t perform that action at this time.
0 commit comments