2011-06-23
One Big Reason to Limit JavaScript Usage
JavaScript is used all over the internet to accomplish a wide variety of features such as hover menus, rollovers, animation, and form validation. In fact, JavaScript is used so frequently that web developers often take it for granted, without realizing that not all browsers support it. Yes, that’s right, not all browsers support JavaScript. And if that isn’t bad enough, many web surfers actually disable JavaScript.

If you’re wondering why anyone would disable JavaScript, take a look at our list below.Reasons Web Surfers Disable JavaScript in Their BrowsersPop-up Windows. Web developers often create annoying pop-up windows which are more irritating than useful. The best way to get rid of them is to disable JavaScript.Security. Security. Security. One of the most common considerations is security, and it is a well known fact that JavaScript can be easily exploited. (This is especially true for users browsing with Internet Explorer.) Additionally, many redirects are accomplished via JavaScript. By disabling JavaScript, you always know exactly where you are going and are less likely to be forwarded to an alternate website.Animations and Sounds. Have you ever been at work and navigated to a website which started playing loud music or sounds?! A lot of this is accomplished by JavaScript. Additionally, by disabling JavaScript, you can also get rid of many annoying animation which clutter the screen or distract you from the information you are trying to see.Annoying Restrictions. Sometimes, websites limit the actions that can be taken by visitors. For example, you have probably seen the websites which stop users from viewing the source code, saving images, or highlighting text.Alternatives to JavaScriptClearly, there are many good reasons an internet users would opt to disable JavaScript in their browsers. And while estimates aren’t too accurate, somewhere between 5 and 7 percent of internet users disable JavaScript. That means that at least 1 in every 20 visitors might not see your website as you intended. So it is important to ensure that your website works properly with or without JavaScript.Fortunately, other internet technologies can accomplish most of what you would probably use JavaScript to do:1. Hover MenusBelieve it or not, you don’t need JavaScript to create a hover menu!Sometimes, however, you might want to create a cool effect which is only possible with JavaScript. In this case, feel free to create the JavaScript menu, but pay special attention to how the menu behaves without JavaScript. Be sure that it can still be used to navigate your website.2. Image RolloversBelieve it or not, this too can be accomplished by CSS by using the :hover’ state to shift the position of an element or show a new element. Either way, rollovers are rarely crucial to the usability of a web page.3. Redirection and Form ValidationFortunately, there are alternatives for these as well. When you use JavaScript, it is always processed on the client-side, which is why users are able to modify the behavior of the web page when they turn it off. Instead, you can opt to do all of your processing on the server-side, by using a programming language. For example, our contact forms use server-side validation to ensure that a valid email address has been entered, even though this could be accomplished with JavaScript. By opting for server-side processing, your users will always be subject to certain restrictions.Similarly, you can use a programming language to redirect users to other web pages.4. Animation and Pop-upsFor animation, there are two alternatives: (1) create an animated gif image, or (2) use flash. Both of these methods have their drawbacks. With the animated gif image, you are limited to creating an image with a reasonable filesize. (The longer the animation or larger the image, the larger the filesize.) And finally, if you opt to use flash, you will encounter some of the same problems you encountered with [removed] Not All Visitors Enable Flash. And like the animated gif, you are likely to have some filesize issues as well.
As for pop-ups, we’re at a loss. Instead, you will have to bait your users to click on a link which would open in an external window or tab
(Let us know if you’ve found suitable alternatives.)So if you are building a website, you are free to use JavaScript. But its should only be used on elements that are not crucial to the use of your website. And if, for some reason, JavaScript is essential to the use of an element on your page, consider supplying some alternative text explaining what the element is and that users need to turn on JavaScript to take advantage of it.
similar posts:
Reconstruction Efforts Hampered By Voles : Greetings,...
I would have loved to see Elvis perform in person : I wish I...
Uses of Cloud Computing for small scale organisations : I’ve...
Website Design - Present Your Venture Online! : The internet...


