Hi all,
The file which containes Ajax code . Can save it as .html file or i need to
save it as jsp file.
when i tried using html it is not working properly,but when i changed it to jsp it worked well. Why so?
We can't save a file which has Ajax code as html.
Thanks inadvance.
Regards,
Nageshwarrao.a
First you need to understand what AJAX is. It's not a type of language or code, it's just a method, a way to use existing languages and implementations.
It's typically done using javascript and a server side scripting language. For example, you could have a javascript interact with a PHP or JSP script on the server. The idea is to do the work whilst the user is viewing the page, then dynamically (dhtml / js) change the contents of the page, thus removing page reloading.
So, if you've written some javascript, the file extension should be .js
Please do not confuse JSP with Javascript. JSP is Java - not Javascript. JSP is a server side language, much like ASP, PHP, Perl, Ruby, etc...