Page 1 of 1
Javascript+PHP vs. Ajax
Posted: Thu Oct 05, 2006 3:04 pm
by JellyFish
What can Ajax do (Javascript and XML) that Javascript and PHP can't do?
Posted: Thu Oct 05, 2006 3:24 pm
by Burrito
you're comparing apples and oranges.
Ajax is not synonymous with XML and XML is not compariable to PHP.
'Ajax' or XMLHttp is a javascript object that can interact with PHP or any other back end server side language and communicate via XML (or not).
I would hit up wikipedia for Ajax if I were you.
Posted: Thu Oct 05, 2006 3:40 pm
by JellyFish
Okay. Danka you Burrito. I'll be back if I have more questions after my research.

Posted: Thu Oct 05, 2006 3:45 pm
by Luke
yup, you don't even have to use XML...
JSON is much cooler for most things... it can be parsed natively by Javascript, because it's just a subset of object literal notation.
Posted: Sun Oct 15, 2006 9:44 pm
by JellyFish
What I mean is. Can I go through the whole website without any page refreshes with PHP+Javascript?
Posted: Sun Oct 15, 2006 11:42 pm
by Zoxive
JellyFish wrote:What I mean is. Can I go through the whole website without any page refreshes with PHP+Javascript?
Thats what Ajax does.. Ajax simply is just Javascript that uses the XMLHttp Object..
This page helped me out when i first started playing around with Javascript/Ajax.
-NSF
Posted: Mon Oct 16, 2006 2:06 am
by JellyFish
Yeah but I don't know Ajax, will eventually learn it. Does Ajax have access to mySql database? Can javascript and php access mysql database without any page refresh???
Posted: Mon Oct 16, 2006 2:21 am
by Luke
I think you are getting confused... AJAX is NOT a language of any kind. AJAX is a technique. Basically the idea is: Using client-side code (Javascript) to send a request to server-side code (PHP, Ruby on Rails, JSP, etc.) which returns some sort of structured data (structured data could be anything from a comma-delimetted list to JSON and XML) which is then parsed and/or executed by the client code... all without refreshing the page.
Posted: Mon Oct 16, 2006 4:53 am
by Chris Corbyn
To be extremely to the point: AJAX is JavaScript + PHP.
Posted: Mon Oct 16, 2006 4:31 pm
by JellyFish
Yeah Ajax is a combanation of technologies, but I never knew php was included the list of those technologies. Thanks for clearing that up guys.

Posted: Mon Oct 16, 2006 4:40 pm
by Luke
pretty much anything that can generate output to the browser is included...
Posted: Mon Oct 16, 2006 4:40 pm
by Chris Corbyn
JellyFish wrote:Yeah Ajax is a combanation of technologies, but I never knew php was included the list of those technologies. Thanks for clearing that up guys.

It doesn't have to be PHP specifically; it just needs to be a server side language. ASP, Perl or JSP would all work as well as PHP

Posted: Mon Oct 16, 2006 4:48 pm
by Luke
d11wtq wrote:JellyFish wrote:Yeah Ajax is a combanation of technologies, but I never knew php was included the list of those technologies. Thanks for clearing that up guys.

It doesn't have to be PHP specifically; it just needs to be a server side language. ASP, Perl or JSP would all work as well as PHP

Technically it doesn't even need to be that... you can request a static page and parse the results with javascript if you really want to...
Posted: Mon Oct 16, 2006 4:53 pm
by Chris Corbyn
The Ninja Space Goat wrote:Technically it doesn't even need to be that... you can request a static page and parse the results with javascript if you really want to...
Ok smart ass

Posted: Mon Oct 16, 2006 4:54 pm
by Luke