Hijax
Hijax is a term for the application of progressive enhancement to AJAX. It is also known as 'Simplified Ajax'[1]. Hijax was proposed by Jeremy Keith [2] as a technique for building web applications that degrade gracefully by only using AJAX techniques to 'hijack' form submissions and responses, updating the DOM to reflect the results of the request/response cycle.
Contents |
[edit] Development history
Ajax has truly revolutionized the web by creating a far better user experience. Gone are the days with long waiting for complete page loads during switching from one page to another. With Ajax only the target content is updated with less time, consumes less server-side resources, and reduces bandwidth loads drastically. However it was incapable of remembering the user's history and bookmarking as Ajax made no changes to the URL. Then came the URL hashing concept and the problem could be solved. But another important issue remained: web crawlers find it difficult to crawl into Ajax-based websites and hence became SEO unfriendly. Google implemented the concept of 'hashbang' to solve this problem too. (Exclamation sign (!) is used just after hash symbol (#) like in www.example.com/#!newcontent). But still not every search engine have adopted this, so AJAX is still a challenge for search engine optimization (SEO).
Problems like these could be solved using new techniques but the biggest problem faced by AJAX applications is its backward compatibility. For devices that do not support JavaScript, or simply has this functionality disabled, or that doesn't support XMLHttpRequest (XHR), Ajax is not just useless but also a huge problem as the content is not accessible. For this reason AJAX has faced many criticisms like "...it must degrade well. It must still be accessible. It must be usable. If not, it is a cool useless piece of rubbish for some or many people."
[edit] What is hijaxing
Without Ajax, normal hyperlinks make the web browser load a new web page, and the entire website has to get loaded. With Ajax only a target page element gets updated, and except for the hash segment of the URL everything else is untouched. Hijax comes as hybrid. It makes use of an API in which each link or form points to a particular DOM element. When a link or a form is clicked, you can clearly see the browser's reloading signs and the new updated with updated URL and exactly the desired page elements updated, everything else remains untouched. This is what everybody wanted and it is possible with Hijax. Now even in the absence of JavaScript the URL still points to the page with new content so is a graceful degradation and of course is a Progressive enhancement, that is you're starting out with just basic content, and want to add better functionality for browsers that support it without breaking the site for those that do not.
[edit] References
- ^ "HIJAX - Simplified Ajax". http://www.ajaxwith.com/HIJAX-Simplified-Ajax.html. Retrieved 12/21/11.
- ^ Keith, Jeremy. "DOMScripting". Hijax. http://domscripting.com/blog/display/41/. Retrieved 12/21/11.