카테고리 없음

The Problems with AJAX

znoflo 2007. 5. 3. 10:01

AJAX를 사용하면서 가장 우려가 되는 부분이 하나 있는데 바로 검색엔진에서 검색이 안된다는 것이다. 자바스크립트로 데이터를 요청하기때문에 페이지 안에서 시시각각 변화하는 내용들을 검색엔진이 어떻게 크롤링하랴. 이 문제를 다른 사람들은 어떻게 풀어가고 있는지 해결책을 찾아봤더니 문제점만 수두룩... OTL... 그 중에 AJAX의 단점에 대해서 잘 정리한 내용이 있어 퍼왔다. AJAX로 개발하시는 사람들은 아래 문제들을 꼭 짚고 넘어가야 할 것이다.

AJAX is the latest industry buzz-word and to hear people talk you''d think it''d have to be the best thing since sliced bread. I''ll go on record as saying that I think AJAX is awesome but, since every other article touts how amazing it is, I''d like to play devil''s advocate and point out a few of it''s flaws.

JavaScript - AJAX functions entirely by using lots of client-side JavaScript to send requests to the server and update data on the page. No JavaScript means that none of your cool functionality works at all. Providing a non-AJAX alternative may require a lot of extra work.

The Back Button - This is fairly similar to what happens with Flash sites. The user does something, does something else, then wants to return to the previous task so they click the back button. When you''re serving normal HTML pages this works great. In an AJAX application however, the back button is essentially rendered useless.

Analytics - Having standard HTML pages provides an easily mechanism to track what your users are doing. AJAX slightly complicates this by replacing some of the pages with asynchronous JavaScript calls. While not impossible, it does have the potential to add a layer of complexity to capturing analytical data. I should note however, that there are companies such as Crazy Egg that are actively working to solve this problem.

Accessibility - Having pages that rely heavily on JavaScript and updating dynamically has the potential to wreak havoc on screen reader type programs for users with visual impairments.

Search Engine Optimization - At this time it may be difficult for search spiders to properly index content returned through complex AJAX updates.

Pasting a Link - The page updates frequently but the address bar never changes. When you cut and paste the link to your buddy, they just see the homepage instead of the info you intended. (Google Maps solves this nicely with a ''Link to this Page'' button that updates the URL)

I''m certainly not trying to discourage AJAX use as none of these issues is insurmountable. As with all new technologies however, I would encourage caution and careful consideration before deploying. It''s important to understand why you''re using the technology instead of using it just to brag that you built an AJAX site. Remember when everyone had to have an all-Flash site, or crazy DHTML? That was the cool thing to do but people quickly learned that it wasn''t always the right thing to do. I would urge people to remember that lesson and use the same caution here. AJAX is a fantastic technology and can be greatly beneficial when used properly. Let''s do our best to ensure that it stays that way.

I''m out of town for a few days but after that I''ll be back with some code samples on how to do some pretty neat things using ASP.NET 2.0 and Atlas.



출처 : http://www.codescene.com/2006/05/the_problems_with_ajax.php


AJAX... 이래저래 고민할 부분이 한두가지가 아니지만... 왠지 그래서 더 끌린다. 기필코 언젠가는 모두 만족시켜주고 말테닷!