Webmaster Forum

Go Back   Webmaster Forum > Web Development > Coding Forum

Coding Forum Problems with your code? Discuss coding issues, including JavaScript, PHP & MySQL, HTML & CSS, Flash & ActionScript, and more.


Reply
 
Thread Tools Display Modes
Share |
  #1  
Old 02-26-2010, 12:26 AM
alter-ego's Avatar
alter-ego alter-ego is offline
v7n Mentor
 
Join Date: 03-03-09
Location: Lower Mainland B.C.
Posts: 1,301
iTrader: 0 / 0%
Chrome not displaying ' properly in javascript

I'm using javascript to display rotating inspirational quotes on my rotating background headers and it works perfectly in every browser it seems except google chrome and only when I try to display an '.

For example:

Code:
quote[44]='<a href="http://www.lifesupporters.com/"><img src="/media/images/success.gif" border="0"></a> When it is obvious that the goals cannot be reached, \don\'t adjust the goals, adjust the action steps.<br /><div align="right"><font size="1"><i>~ Confucius</i></font></div>'
The word \don\'t displays as don't in every browser I tested but in Chrome it comes up as don?t. I suppose I could make the apostrophe an image but I was wondering if there was something I could do that was a bit less cumbersome.

Anyone have any ideas on how to fix this?
 
Reply With Quote

Advertisement

Advertisement

  #2  
Old 02-26-2010, 12:47 AM
HTMLBasicTutor's Avatar
HTMLBasicTutor HTMLBasicTutor is offline
Administrator
 
Join Date: 10-29-07
Location: Canada
Posts: 26,637
iTrader: 5 / 100%
What happens if you use:
[Didn't work]
instead?
Ref: http://webdesign.about.com/od/locali...odes-ascii.htm

Edit: You'll have to look on the referenced page. The form interpretted the ASCII code and showed a '
 
Reply With Quote
  #3  
Old 02-26-2010, 08:58 AM
alter-ego's Avatar
alter-ego alter-ego is offline
v7n Mentor
 
Join Date: 03-03-09
Location: Lower Mainland B.C.
Posts: 1,301
iTrader: 0 / 0%
Quote:
Originally Posted by htmlbasictutor View Post
What happens if you use:
[Didn't work]
instead?
Ref: http://webdesign.about.com/od/locali...odes-ascii.htm

Edit: You'll have to look on the referenced page. The form interpretted the ASCII code and showed a '
OMG that never even occurred to me which is embarassing given how often I rely on @nbsp;

Thanks for the response html, I'll give it a try and report back.
 
Reply With Quote
  #4  
Old 05-19-2010, 08:15 AM
alter-ego's Avatar
alter-ego alter-ego is offline
v7n Mentor
 
Join Date: 03-03-09
Location: Lower Mainland B.C.
Posts: 1,301
iTrader: 0 / 0%
I know its a late update but the actual code that works for all browsers (including Google Chrome) is the Hex Code &#x27;

For example:

it's = it&#x27;s
 
Reply With Quote
Go Back   Webmaster Forum > Web Development > Coding Forum

Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
IE 7 displaying different that FF, Chrome, Safari lajones3 Coding Forum 5 11-19-2009 10:01 AM
Google Chrome 2 Public. Here comes Chrome 3! StarLab Google Forum 10 06-09-2009 12:52 PM
Website not displaying properly in IE Colin Behr Coding Forum 6 12-06-2008 10:17 PM
note displaying properly in internet crapsplorer. jdog Coding Forum 2 12-02-2006 05:14 PM
Adsense Link units not displaying properly Janet Contextual Networks 3 04-17-2006 07:51 PM


V7N Network
Get exposure! V7N I Love Photography V7N SEO Blog V7N Directory


All times are GMT -7. The time now is 01:40 AM.
Powered by vBulletin
Copyright 2000-2014 Jelsoft Enterprises Limited.
Copyright © 2003 - 2018 VIX-WomensForum LLC