From the course: Ajax with PHP: Add Dynamic Content to Websites

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Allow fallback to HTML

Allow fallback to HTML

From the course: Ajax with PHP: Add Dynamic Content to Websites

Start my 1-month free trial

Allow fallback to HTML

- [Narrator] There's one more topic I want us to consider about our Ajax forms design. It works great, if the user has JavaScript enabled, but what if the user has disabled their JavaScript? What if they're clicking the submit button to submit a plain old HTML form? In that case, we need to ask ourselves, can we give non-JavaScript users a decent experience on our site as well? We should always consider this whenever we're putting any kind of JavaScript features in, whether they are Ajax features or not. And the answer really depends on the context. Sometimes it's going to be possible to have fallbacks to HTML and sometimes it may not. This is really part of a larger topic called Progressive Enhancement. The idea is to make your website functional for everyone but then browser, which have more capabilities, are given additional features or enhancements. But the site still works for the lowest common denominator. The idea is to make those special site features all degrade gracefully…

Contents