Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Catering for Non JS users

Featured Replies

Hey guys.

 

I am working on a site right now, and want the site to be 100% for non javascript users. I tested the site with my browser js turned off and somethings just look plain bad. Naturally I want the site to be the best I can do for all users and even though non js users only count for a tiny portion of visitors, i believe it should still work for them as its intended.

 

Some of the more obvious issues are:

1. The navigation drop down doesn't work. This isn't really a big issue as the main nav sections have sub menus on their respective pages.

2. Sliders don't work, and just shows the loading bar.

3. The embedded google maps doesn't work. Just shows a blank square.

4. The site is a wordpress site, and uses Slick Social Contact Form, and Slick Social Tabs. If you never used these before you put them in a widgetised area but they don't appear there, they appear to float on the page (intended), however with js off, they appear in the footer and look really horrible. On the website for these plugins one solution is provided using css to hide them from the footer, but I only have it for the contact form, and not the social tabs (I have emailed the plugin dev to see if they have a similar fix).

 

My main question really though is, do you cater for non js users and is there a universal fix all solution?

 

Thanks.

Hey guys.

 

I am working on a site right now, and want the site to be 100% for non javascript users. I tested the site with my browser js turned off and somethings just look plain bad. Naturally I want the site to be the best I can do for all users and even though non js users only count for a tiny portion of visitors, i believe it should still work for them as its intended.

 

Some of the more obvious issues are:

1. The navigation drop down doesn't work. This isn't really a big issue as the main nav sections have sub menus on their respective pages.

2. Sliders don't work, and just shows the loading bar.

3. The embedded google maps doesn't work. Just shows a blank square.

4. The site is a wordpress site, and uses Slick Social Contact Form, and Slick Social Tabs. If you never used these before you put them in a widgetised area but they don't appear there, they appear to float on the page (intended), however with js off, they appear in the footer and look really horrible. On the website for these plugins one solution is provided using css to hide them from the footer, but I only have it for the contact form, and not the social tabs (I have emailed the plugin dev to see if they have a similar fix).

 

My main question really though is, do you cater for non js users and is there a universal fix all solution?

 

Thanks.

 

Well for your drop downs you could use a css drop down menu? For your sliders I can think of any other way to fix that other than show them all or use flash?Google maps use JS to call the map, you could embed the image version if JS is turned off? Check google maps static api heres an example of the code:

 

http://maps.googleapis.com/maps/api/staticmap?center=Brooklyn+Bridge,New+York,NY&zoom=14&size=512x512&maptype=roadmap
&markers=color:blue%7Clabel:S%7C40.702147,-74.015794&markers=color:green%7Clabel:G%7C40.711614,-74.012318
&markers=color:red%7Ccolor:red%7Clabel:C%7C40.718217,-73.998284&sensor=false

 

as for Slick Social Contact Form I couldn't comment with out seeing it... which I haven't. Personally I try to avoid js unless I really need to, css3 can do some amazing stuff. A simple solution would be to use php to check if the browser accepts js and work accrodingly, have a look here: http://php.net/manual/en/function.get-browser.php

 

hope it helps :)

  • Author

Well for your drop downs you could use a css drop down menu? For your sliders I can think of any other way to fix that other than show them all or use flash?Google maps use JS to call the map, you could embed the image version if JS is turned off? Check google maps static api heres an example of the code:

 

http://maps.googleapis.com/maps/api/staticmap?center=Brooklyn+Bridge,New+York,NY&zoom=14&size=512x512&maptype=roadmap
&markers=color:blue%7Clabel:S%7C40.702147,-74.015794&markers=color:green%7Clabel:G%7C40.711614,-74.012318
&markers=color:red%7Ccolor:red%7Clabel:C%7C40.718217,-73.998284&sensor=false

 

as for Slick Social Contact Form I couldn't comment with out seeing it... which I haven't. Personally I try to avoid js unless I really need to, css3 can do some amazing stuff. A simple solution would be to use php to check if the browser accepts js and work accrodingly, have a look here: http://php.net/manual/en/function.get-browser.php

 

hope it helps :)

I will have a read up of that now. Good idea on the google map issue will have a look at that now. :D

 

Thanks very much and +1 :)

You don't need to use PHP to check for Javascript support.

 

The currently accepted solution (as used by a few frontend frameworks) is to give your body element a class of "no-js" and remove it with Javascript if available.

Who doesn't have javascript enabled anyway?

I don't know lol I've never met anyone who turns it off... Only a nice old guy my brother works for who's blind and uses a text only browser called Lynx. I guess if you were using js to call your content to the page that would be an issue? but as it stands I can't see another problem that would effect him?

 

And I know you don't need php to detect js but its just another way, e.g. <noscript>

 

Anyway glad the the post helped!

Edited by StonehouseDesigns

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.