What do i do whn i run my page in a browser that does not support Javascript… Is there anyway to request user to install a component for it to run ??
If the browser doesn’t support JavaScript then it doesn’t support it, there’s no way to brute force it to work from what i recall
There is a standard technique to deal with this.
-
Design your HTML so that it makes sense when no scripting, no CSS is involved. This can involve using web forms and buttons to achieve certain results.
-
Use CSS to adjust the presentation of your site so that it looks nice and pretty.
-
Use JavaScript to add behaviour to your site, which can improve the user experience by overriding those earlier web forms and buttons.
It’s much easier to build required functionality from the ground up (progressive enhancement), than to attempt to retro-fit it later on (graceful degredation).
By using such techniques, you can ensure that your web site is easy to manage, and is capable of being used by a wide variety of users.
Sorry i meant on a browser where Javascript is disabled… How do you prompt the user to enable it ??
You leave a message in the HTML informing the user that you have built the page with Javascripted users in mind. Javascript hides this message, so only users without Javascript see it.
However what Paul says is much nicer if you can do that: the goal is, users without Javascript don’t know they’re missing anything. Users with Javascript don’t think anything of the extra enhancements they have.
Remember Javascript can be blocked from someone’s work, school, public library or other place, so if Javascript isn’t essential remember the frustrating of users who get a big ugly message saying "turn on Javascript’ when they’re all like “But I can’t!”
This also means, don’t use <noscript> tags for your message: if the browser has scripts enabled, but scripts are blocked at the router, the user’s browser won’t render the noscript tags. Use normal HMTL tags. Let Javascript throw a class on that tag which is CSS-styled to display: none on page load.
My boss was pissed that he couldn’t view his analytics from his phone (Sony Ericsson) because they were silly and required ajax to log in… but at least they told him why it didn’t work. : )
The best solution is to ensure that the page will work without it so that those without JavaScript do not even realise that the page has any JavaScript.
This shows that “on average” the number of javascript disabled browsers is relatively tiny. Googling various figures on the www I get the impression that globally the figure is less than 5%.
IE6 usage is also around 5% too (6% international, 2% US), but some of us still support it.
http://gs.statcounter.com/#browser_version-ww-monthly-200911-201011 (pretty graphics)
Anything over 1% is worth putting some thought to.
don’t get me wrong.
I’m not saying javascript disabled browsers should not be supported, but that low figure is probably why many clients decide it is not worth any extra costs to them to have their websites support javascript disabled browsers.
Of course then they might need very deep pockets in order to be able to afford the anti-discrimination court case. I believe Kmart settled such a case before it went to court for several million dollars on the understanding that they would immediately alter the functionality of their site so that it would work without JavaScript.
The group of people without JavaScript includes a large number of disabled people who are unable to use a browser that dsupports JavaScript at all. This makes it a very different situation from IE6 which no one if forced to use.
yep but I suppose it depends on the client’s local laws and the onus imho is on the client to ensure the website specifications they provide the developer doesn’t breach any laws in the jurisdiction the client is under.
That could get interesting. When dealing with products in the marketplace, are Chinese manufacturers responsible for bad products, or are the US companies who provide the specifications. Often we prefer to demonise the Chinese manufacturers instead.
As web developers, we have a responsibility to advise our clients of potential problems. If they don’t want to pay for us to deal with those problems, it’s our own responsibility whether we carry on with the project.
Not just on their local laws. If their site is hosted in a different country then the laws in that country may apply as well. There may also be circumstances where the laws of the country where the visitor resides may also be applicable - particularly if there is something in the web site that shows that its intended audience includes that country. The safest and cheapest option is to make sure that the site works without JavaScript.
yep agree :agree:
I will advise a client of the potential pitfalls in user experience for not supporting javascript disabled browsers, but I will definitely not advise the client, or potential client, on whether they have any legal obligations to support javascript disabled browsers. The client can get their own legal advice on that issue and then decide for themselves which way they want to go.
Then if the project specifications suit me, I will be happy to give them a quote or even two quotes. One for javascript enabled browsers and one for javascript disabled browsers if the scope of the specifications warrants it.
That is for the client, and not me as a developer, to decide and to write up their specifications accordingly.
The client should get their own legal advice because I am not a lawyer and so I can only advise on the user experience pitfalls, not any legal implications.
You need to make sure that if they do make that decision that you have a contract that ensures that they accept full responsibility for any consequences of that decision. After all if they end up getting sued and it costs them ten million you don’t want them trying to recover their money by suing you.
yep :agree: and that is what I do with any agreement/contract I sign.
Use “lynx browser”