Friday, March 5, 2010

A good Ajax programming

This paper was inspired by my writing here where one reader commented that ajax is not like what I say. It is true that we can not judge that a useful technology or not simply by looking at only 2 results. Actually I am just write my frustration spilled will difficult to access my email on Yahoo and Gmail by default directs users to view full ajax. Thank you so much for the response. For that I want to write my opinion about a good use of ajax.



Ajax is the latest web technology that enables user interaction and the web more attractive and also more efficient in data transfer Why? Because by using ajax we can refresh or load some content that needs to be updated by other web parts such as header, footer, sidebar, and other parts do not need to re-load. We just load the content and the course changed. Thus be more efficient in data transfer, more responsive applications, and users more easily interact with the web like desktop applications. On web technology before ajax to display content that changes we must load the entire web page without caring that there are parts of web content does not change. But there are some shortcomings that ajax technology to be able to work must use a browser with javascript functions in the switch. Without javascript, ajax will not run. Lack ajax technologies are:

* Content is displayed with ajax can not be read by search engines. This is because the javascript is active only in the browser, search engine bots can not run javascript. Whereas most of the web getting new visitors from search engines. As a result our content won't be indexed on search engines and hard to find from search engines.
* Can only be run on the latest browser. I used to create applications with ajax features to be used internally in my office working. It turned out that many office computers are still using Windows XP without service pack 2. The results with Internet Explorer 6 that do not support ajax then my application can not be used on several computers. To install service pack 2 or the latest firefox is not an easy job with the number of computers close to hundreds.
* Web that uses ajax be difficult to display on mobile devices. There are many internet users to use mobile phones to access the Internet while relaxing. Mobile browser almost 80% did not support javascript ajax does not work when displayed on the mobile phone browser.

Therefore, excessive use of ajax and out of place will hurt us because the developers or users of our web visitors will have difficulty in accessing and using the web we develop it. For it is tips and tricks on using ajax correctly on your application or website:

1. Think about your target users, if your target is mobile phone users for example to sell mobile content then forget to use ajax. Because your users or visitors can not access it properly. What's the point you develop your web application or without any user.
2. Use only for ajax content dynamic really very often changed alias. Do not use the content that rarely change such as content on the blog. Writing on blog are very rarely changed once posted. Usually only a small update to fix some of the writing. Although the concept, with the template and the same layout each post will allow the use of ajax but in this case harm your ajax. Because of your blog's content is not readable by search engines and visitors will have difficulty finding your article on search engines. Examples of frequently changing content is livescore.com display that automatically reload sporting results periodically in a certain time frame. Outcome score can be updated without reload the whole look of the website.
3. Use the submit form or upload files. For example you can use ajax in filling such comments and loaded with ajax to display the new comments you submit. Or upload a file with ajax without having to reload the entire site.
4. In web applications usually do not require access to search engines, because only the application addressed to the user. Because it is more flexible use of ajax. You can use the ajax anywhere in your application as a web application typically has a very dynamic content. Also more applications require fast response from the user interaction that can be done with ajax. But keep in mind, you should not make excessive load objects that then we can easily update the content with ajax and javascript as show with my writing in advance about gmail and yahoo mail is too much access to early access. Consider always the size of your web page, because although the display is more responsive but at the initial load will take a long time.
5. Always use loading or status indicators from ajax. Ajax make requests or so-called callback without providing its own health meter. Programmer must make to be able to tell whether or callback request is successful, is loading, or fail. Thus, users do not click or excessive request of not knowing whether he had made request or not and also the user does not wait too long without knowing the outcome.

That's my opinion about web programming with ajax. Thank you.

1 comment:

Unknown said...

Well written article.In this article Ajax programming is the new version of programming.But the lacks of this programming shows its difficulty in regular use.Some tricks and tips also mentioned but these are not so much effective.
electronic signatures