views:

73

answers:

4

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.

A: 

I say, as long as you consider ALL your users, i.e. mobile/text-only/low bandwidth/small screensizes then you will be fine. Too many developers just do it for their huge 19" screens and 10Mbps, that users to get left behind through almost no fault of their own.

Tim Green
Screen size is totally unrelated to the question.
HoLyVieR
Was just an example.
Tim Green
I do like the point of mobile users. I honestly don't know what mobile browsers (if any) can support ajax.
Capt Otis
+1  A: 

"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.

shane
A: 

First disadvantage is that users with javascript turned off won't be able to use the site.

Another disadvantage of using AJAX is that web crawling sites might have trouble indexing your site, depending on the structure of your dynamic content (Making AJAX Applications Crawlable). This might be a problem if you depend on search engines to get users to your site.

BrokenGlass
+1  A: 

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.

Brian Flanagan