Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls

Detect For Non Javascript enabled users, and Warn them!

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #11  
Old 05-09-2003, 01:10 PM
  B00MER's Avatar 
B00MER B00MER is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Keller, TX (Cart-Lab.com)
Posts: 3,165
 

Default

Yes it is safe to do such.

http://www.htmlhelp.com/reference/html40/block/noscript.html

One thing ive noticed however is google and other search engines alike are picking up the no script text as the first part of a site for description, not pickup the meta tag description and using it instead so for you search engine optimization junkies be aware of such.
__________________
Cart-Lab - 100+ Social Bookmarks for X-Cart.
Reply With Quote
  #12  
Old 05-09-2003, 01:23 PM
  BoomBoomBap's Avatar 
BoomBoomBap BoomBoomBap is offline
 

Senior Member
  
Join Date: Nov 2002
Location: San Francisco
Posts: 184
 

Default

That's very worthwhile information Boomer!

I've gone ahead and updated the noscript content with site information preceding the error.

Im still nervous about enclosing the entire site in <script></script> tags however...
__________________
Site 1 > XCART LIVE 3.4.12

Site 2 > XCART LIVE 4.0.17
Reply With Quote
  #13  
Old 05-09-2003, 01:55 PM
 
machnhed1 machnhed1 is offline
 

eXpert
  
Join Date: Feb 2003
Location: Illinois
Posts: 274
 

Default

FYI... 3.4.0 addresses this issue. As you've probably read, there are varying levels of success with the install, so it's caveat emptor. With that said, I have had no problems, but mine was a clean install to give it a test drive. The point I am getting at here is you may want to hold off that code implementation if you are going to bump up to 3.4.0.

Good luck either way
__________________
Following the signature guidelines : xcart pro 3.5.8 - [RedHat]
Reply With Quote
  #14  
Old 05-09-2003, 01:58 PM
  BoomBoomBap's Avatar 
BoomBoomBap BoomBoomBap is offline
 

Senior Member
  
Join Date: Nov 2002
Location: San Francisco
Posts: 184
 

Default

Can you tell me in what way 3.4.0 addresses the issue? Does is have noscript options or is it simply no longer javascript dependent ?
__________________
Site 1 > XCART LIVE 3.4.12

Site 2 > XCART LIVE 4.0.17
Reply With Quote
  #15  
Old 05-09-2003, 02:08 PM
 
machnhed1 machnhed1 is offline
 

eXpert
  
Join Date: Feb 2003
Location: Illinois
Posts: 274
 

Default

Not 100% certain, since I haven't dissected it yet, but here's what I can tell you. There is a link in the auth.tpl that says
Quote:
If you have disabled Javascript in your browser click here
It changes to
Quote:
If you have enabled Javascript in your browser click here
once you actually click on the link and vice versa.

The code is something like this Other than this all I can offer up is what the change log says
Quote:
Fri Jan 3 16:50:00 MSK 2003 [+] - svowl - This feature allows customers with disabled JavaScript in browsers to make purchases with the X-Cart.
Doesn't help much, I know, but it's the best I can offer up right now.
__________________
Following the signature guidelines : xcart pro 3.5.8 - [RedHat]
Reply With Quote
  #16  
Old 05-09-2003, 05:00 PM
  B00MER's Avatar 
B00MER B00MER is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Keller, TX (Cart-Lab.com)
Posts: 3,165
 

Default

The user still has to see the small link on the auth.tpl to enable/disable the javascript. Which may not be too effective. Integrate both or a simple message that it is reocmmended to enable javascript, and link to the same link the auth.tpl does in 3.4.0 to set the js_enabled var.

Just my 2cents.
__________________
Cart-Lab - 100+ Social Bookmarks for X-Cart.
Reply With Quote
  #17  
Old 05-09-2003, 06:11 PM
  BoomBoomBap's Avatar 
BoomBoomBap BoomBoomBap is offline
 

Senior Member
  
Join Date: Nov 2002
Location: San Francisco
Posts: 184
 

Default

Well that is definitely useful information.

What a neat feature to add !

Thanks for pointing it out :P
__________________
Site 1 > XCART LIVE 3.4.12

Site 2 > XCART LIVE 4.0.17
Reply With Quote
  #18  
Old 05-22-2003, 12:11 PM
  BoomBoomBap's Avatar 
BoomBoomBap BoomBoomBap is offline
 

Senior Member
  
Join Date: Nov 2002
Location: San Francisco
Posts: 184
 

Default

Just a quick note

the following:

<script>
all the original content
</script>
<noscript>
{ include file="nojava.tpl" }
</noscript>

is NO GOOD

Instead, the following is recommended:

Code:
<noscript> <center><table bgcolor="#FFFFFF" width="100%"><tr><td align=center> <FONT COLOR="#FF0000" SIZE="-1">*** ERROR *** JAVASCRIPT IS REQUIRED TO USE THIS SITE! Please CLICK HERE for further instructions </FONT> </td></tr></table> </center> </noscript>


It seems the include file is read into the source code of the document regardless of whether or not the user has Javascript support. Although the information will not be shown to the user it will still appear in the source which is simply a waste of bandwidth. Instead of using an include file I recommend linking to a static HTML file. If you like, feel free to use mine (optimized, added to, and edited from somewhere else mentioned earlier on in this topic). http://www.boomboombap.com/no_javascript.html
__________________
Site 1 > XCART LIVE 3.4.12

Site 2 > XCART LIVE 4.0.17
Reply With Quote
  #19  
Old 07-22-2003, 04:14 PM
  groovico's Avatar 
groovico groovico is offline
 

X-Man
  
Join Date: Apr 2003
Location: Firetanksoftware.com
Posts: 2,326
 

Default

That's a much better solution, thanks boomboombap!

I don't see the point of people turning javascript off in this day and age, it's like turning the ABS off in your car! Ok so maybe not as drastic
__________________
Groovico

Used by X-carters the world over:
Marketing Manager Pro Bundle For X-cart
Featured Product Manager for X-cart
Feed manager pro for X-cart

http://www.firetanksoftware.com

Celebrating 7 Years of providing quality X-cart Add ons and X-cart Mods for x-cart 3.X to X-cart 4.4.X
Reply With Quote
  #20  
Old 03-10-2004, 07:48 AM
 
NuAlpha NuAlpha is offline
 

X-Adept
  
Join Date: Aug 2003
Location: US
Posts: 598
 

Default

Just so you know, Safari is long since out of public beta. You may want to change BoomBoomBap's "no_javascript.html" to show Safari 1.x instead.
__________________
X-Cart Pro 4.5.5 Platinum
X-Payments 1.0.6
PHP 5.3.14
MySQL 5.1.68
Apache 2.2.23
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 12:37 AM.

   

 
X-Cart forums © 2001-2020