Go Back   CodingForums.com > :: Client side development > JavaScript programming > Ajax and Design

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-28-2008, 12:30 PM   PM User | #1
mlse
Regular Coder

 
mlse's Avatar
 
Join Date: Mar 2005
Posts: 624
Thanks: 20
Thanked 19 Times in 18 Posts
mlse is on a distinguished road
Problems with pure AJAX?

Hi all,

I am using more and more AJAX in the websites that I build. I wonder what, if any, are the drawbacks of using AJAX as compared to the standard HTTP submit/response method.
mlse is offline   Reply With Quote
Old 03-28-2008, 02:30 PM   PM User | #2
Stooshie
Regular Coder

 
Stooshie's Avatar
 
Join Date: Mar 2008
Location: Dundee, Scotland
Posts: 376
Thanks: 9
Thanked 39 Times in 39 Posts
Stooshie is on a distinguished road
Accessibility is one drawback. Screen readers are not very good at reading content that is dynamically created by client side scripts.

You can make ajax that degrades gracefully but it can be a lot of work, particularly if you are writing something more along the lines of an online application.
__________________
Regards, Stooshie
O
Stooshie is offline   Reply With Quote
Old 04-01-2008, 08:32 PM   PM User | #3
Basscyst
Smokes a Lot


 
Join Date: Jul 2003
Location: CA, USA
Posts: 1,594
Thanks: 5
Thanked 20 Times in 20 Posts
Basscyst is on a distinguished road
It also breaks the back button, in that if you are using ajax to retrieve all your content, your page will not save state and the user's expected history can become misleading.
__________________
Helping to build a bigger box. - Adam Matthews
Basscyst is offline   Reply With Quote
Old 04-02-2008, 10:33 AM   PM User | #4
mlse
Regular Coder

 
mlse's Avatar
 
Join Date: Mar 2005
Posts: 624
Thanks: 20
Thanked 19 Times in 18 Posts
mlse is on a distinguished road
Yep, I absolutely *HATE* that with a passion when I encounter it! Especially when I trawl a site for a good half hour or more, eventually find the page I want, fail to notice that the URL hasn't changed, smugly hit CTRL+D - then when I visit the bookmark later - hey presto! ... The homepage of the site. (much purple-faced swearing, flying coffee cups, etc ...)

I have a rule for my AJAX - use it to modify existing page content (e.g. highlight a password input and generate a javascript alert when the user has entered the wrong password) but if page content needs to be modified a lot (e.g. change of page) then I use the standard HTTP request mechanism to request a fresh page from the server.

Last edited by mlse; 04-02-2008 at 10:36 AM..
mlse is offline   Reply With Quote
Old 04-03-2008, 01:05 AM   PM User | #5
A1ien51
Senior Coder

 
A1ien51's Avatar
 
Join Date: Jun 2002
Location: Between DC and Baltimore In a Cave
Posts: 2,717
Thanks: 1
Thanked 94 Times in 88 Posts
A1ien51 will become famous soon enough
You could use something like Really SImple History for back button support: http://code.google.com/p/reallysimplehistory/

HTML5 has new tags to also help with this too: http://blogs.pathf.com/agileajax/200...ml5-and-a.html

Eric
__________________
Tech Author [Ajax In Action, JavaScript: Visual Blueprint]
A1ien51 is offline   Reply With Quote
The Following 2 Users Say Thank You to A1ien51 For This Useful Post:
mlse (04-08-2008), oesxyl (04-03-2008)
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 04:43 AM.


Advertisement
Log in to turn off these ads.