Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pros and Cons of an all Ajax Site?

Tags:

ajax

web

So I actually saw a full ajax site somewhere (I forget where) and thought it would be something new and fun to try. I used an old site I had built and put it on a new server. With a little bit of jquery and ajax, I was able to make the entire site work on one page load.

My question is, what are some pros and (more likely) cons to this method?

Please note - the site works through a semi clever linking function. Everything works perfectly fine if the user doesn't have javascript enabled, the newly requested page loads like it would on any other website.

More detail -- Say the user loads the homepage of the site, then logs in. When they log in, the login box fades and reappears with user info. Other content on the page loads as necessary upon logging in. If they click a link, lets say "Articles", one column on the homepage slides up and slides back down with the articles. If they click home the articles slide up and the homepage content slides back down. Things like posting comments, viewing profiles, voting on things, etc. are all done through ajax.

Is this a bad method of web design? If so, why?

I am open to all answers/opinions.

like image 563
Capt Otis Avatar asked Sep 19 '10 20:09

Capt Otis


People also ask

Are there any downsides of using AJAX?

The Downsides of Using Ajax The major drawback is its massive usage and dependency on JavaScript. It should be noted that JavaScript is implemented differently for various browsers, such as Internet Explorer, Netscape, Mozilla, and so on.

Is AJAX good for website?

Ajax is a web developer's best friend because it allows lazy loading to be done. Lazy loading is an optimization technique widely used to optimize online content. Ajax lets its users make asynchronous calls without having to reload the entire web page.

Are the advantages of AJAX?

Advantages of AJAX Some IDE are help us to implement AJAX. Reduce the server traffic in both side request. Also reducing the time consuming on both side response. AJAX is much responsive, whole page(small amount of) data transfer at a time.


2 Answers

IMO, this isn't "bad" or "good". That depends completely on whether or not the website fulfills the requirements. Oftentimes, developers working on AJAX-only sites tend to miss the whole negative SEO impact issue. However, if the site is developed to support progressive enhancement (or graceful degradation depending on your point of view), which it sounds like you have, then you're good. Only things to prepare for are times when the AJAX call can't complete as expected (make sure you're dealing with timeouts, broken links, etc) so the user doesn't get stuck staring at a loading icon. (The kind of stuff you'd have to deal with in any application, really.)

There are plenty of single-page websites out there using heavy JS and AJAX for the UI and they are great. Specifically, I know of portfolio sites for web designers and web app development teams that use this approach. Oftentimes, the app feels a bit like a flash app, but without the need for a special plugin.

like image 118
Brian Flanagan Avatar answered Oct 20 '22 18:10

Brian Flanagan


"Is this a bad method of web design? If so, why?"

Certainly not. In fact, making web-pages behave more like desktop applications, whilst remaining functional to ALL users, is the holy-grail of web-design.

like image 26
shane Avatar answered Oct 20 '22 19:10

shane