Adobe Dreamweaver Forums



Last 10 THreads :         Browser (Last Post : michel_v - Replies : 1 - Views : 2 )           »          certificate (Last Post : jkhgdkhgslkj - Replies : 2 - Views : 3 )           »          Flex with JSP (Last Post : JB2622 - Replies : 5 - Views : 6 )           »          Is there a way to extract a subset of an arraycollection (Last Post : Amy Blankenship - Replies : 4 - Views : 5 )           »          Getting Tree Item Editor to show on an Event other thanitemClick (Last Post : ericbelair - Replies : 2 - Views : 7 )           »          mxmlc - "Unable to resolve resource bundle "rpc" forlocale "en_US" (Last Post : ugrowemweschickm - Replies : 2 - Views : 6 )           »          export hidden layers error (Last Post : gelon - Replies : 0 - Views : 1 )           »          Dynamic dropdown (Last Post : idesdema - Replies : 0 - Views : 1 )           »          Re: Dynamic dropdown (Last Post : Ian Skinner - Replies : 0 - Views : 1 )           »          perform action "on save"? (Last Post : AXEmonster - Replies : 1 - Views : 6 )           »         


Home Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
User Info Statistics
Go Back   Adobe Dreamweaver Forums > Other Macromedia/Adobe Products > Cold Fusion
 
Tags:

Reply
  #1 (permalink)  
Old 07-21-2008, 10:16 AM
Chris Loftus
 
Posts: n/a
Diggs:
Default GBP (?) sign

I am currently working on an intranet system that uses ColdFusion and mySQL,
the system is quite dated, whilst I've been adding and updating features I've
come across a strange problem.

Simply put, when I insert a ? (GBP) sign into the database (processed with
ColdFusion), and then output it using CF, it displays a small square box '?'
(as if the font doesn't have that character, Verdana, 10px). I have checked the
value in the database using phpMyAdmin, and it displays the GBP sign correctly.

The page is using XHTML 1.0 Transitional doctype and 'iso-8859-1' charset.

Adding values into the database is done with a simple form, with no processing
done from CF apart from a mySQL query to insert the data. Outputting the values
is also simple, just grabbing the data from the query and printing it.

I have come across this
http://www.experts-exchange.com/Soft...rs/ColdFusion/
Q_20983733.html using Google, however I have tried it twice without success.

We are running ColdFusion 7 with Windows Server 2003.

Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-21-2008, 11:16 AM
GArlington
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

On Jul 21, 10:59 am, "Chris Loftus" <webforumsu...@macromedia.com>
wrote:
> I am currently working on an intranet system that uses ColdFusion and mySQL,
> the system is quite dated, whilst I've been adding and updating features I've
> come across a strange problem.
>
> Simply put, when I insert a ? (GBP) sign into the database (processed with
> ColdFusion), and then output it using CF, it displays a small square box '?'
> (as if the font doesn't have that character, Verdana, 10px). I have checked the
> value in the database using phpMyAdmin, and it displays the GBP sign correctly.
>
> The page is using XHTML 1.0 Transitional doctype and 'iso-8859-1' charset.
>
> Adding values into the database is done with a simple form, with no processing
> done from CF apart from a mySQL query to insert the data. Outputting the values
> is also simple, just grabbing the data from the query and printing it.
>
> I have come across thishttp://www.experts-exchange.com/Software/Server_Software/Web_Servers/ ...
> Q_20983733.html using Google, however I have tried it twice without success.
>
> We are running ColdFusion 7 with Windows Server 2003.


Try UTF-8 encoding
Reply With Quote
  #3 (permalink)  
Old 07-21-2008, 11:16 AM
PaulH **AdobeCommunityExpert**
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

Chris Loftus wrote:
> I am currently working on an intranet system that uses ColdFusion and mySQL,


what version of mysql? what db driver?

> Simply put, when I insert a ? (GBP) sign into the database (processed with
> ColdFusion), and then output it using CF, it displays a small square box '?'


verdana does contain that glyph but you can also see empty boxes when the
encoding is just a bit off.

> (as if the font doesn't have that character, Verdana, 10px). I have checked the
> value in the database using phpMyAdmin, and it displays the GBP sign correctly.


doesn't count--if the db's mangling that data, it's un-mangling it as well.

> The page is using XHTML 1.0 Transitional doctype and 'iso-8859-1' charset.


if you mean via metaheaders, doesn't matter to cf.

> I have come across this
> http://www.experts-exchange.com/Soft...rs/ColdFusion/
> Q_20983733.html using Google, however I have tried it twice without success.


ignore the metaheader bits, nonsense as far as cf goes (but always add them for
forensic reasons, screen readers, etc.).

> We are running ColdFusion 7 with Windows Server 2003.


ok, cf6 & above default to utf-8, so that's probably where the "minor" encoding
mismatch is happening (or the db driver). have you tried

<cfset setEncoding("form","iso-8859-1")>

to your application.cfm?

Reply With Quote
  #4 (permalink)  
Old 07-21-2008, 12:01 PM
Chris Loftus
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

[Q]what version of mysql? what db driver?[/Q]

MySQL 4.1.22-community-nt

[Q]ok, cf6 & above default to utf-8, so that's probably where the "minor"
encoding mismatch is happening (or the db driver). have you tried

<cfset setEncoding("form","iso-8859-1")>

to your application.cfm?[/Q]

yep, no change

Reply With Quote
  #5 (permalink)  
Old 07-21-2008, 12:01 PM
Stressed_Simon
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

Try changing it to &pound; instead that is the HTML entity for it!
Reply With Quote
  #6 (permalink)  
Old 07-21-2008, 12:01 PM
Chris Loftus
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

Thanks Simon, &pound; works :-)

Is there a function that will make this process more dynamic?
Reply With Quote
  #7 (permalink)  
Old 07-21-2008, 01:01 PM
PaulH **AdobeCommunityExpert**
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

Stressed_Simon wrote:
> Try changing it to &pound; instead that is the HTML entity for it!


depending on the application that's not a good solution. won't sort right, can't
be searched for properly (without some form of massaging), etc. and that still
leaves the underlying encoding issue which will almost certainly bite him again
somewhere down the line.
Reply With Quote
  #8 (permalink)  
Old 07-21-2008, 01:01 PM
PaulH **AdobeCommunityExpert**
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

Chris Loftus wrote:
> [Q]what version of mysql? what db driver?[/Q]
>
> MySQL 4.1.22-community-nt


and the db driver?

what is the db encoding?
Reply With Quote
  #9 (permalink)  
Old 07-21-2008, 01:01 PM
Chris Loftus
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

[q]Originally posted by: Newsgroup User
Chris Loftus wrote:
> [Q]what version of mysql? what db driver?[/Q]
>
> MySQL 4.1.22-community-nt


and the db driver?

what is the db encoding?
[/q]

Sorry, where can I check this information Paul?

Reply With Quote
  #10 (permalink)  
Old 07-21-2008, 01:41 PM
PaulH **AdobeCommunityExpert**
 
Posts: n/a
Diggs:
Default Re: GBP (?) sign

Chris Loftus wrote:
> Sorry, where can I check this information Paul?


db driver is what you used to setup the dsn for that db (via cfadmin).

i'm no mysql expert but try this in either a cfquery or in whatever you use to
admin the db:

SHOW CREATE DATABASE `DB_NAME`

i suspect if you don't know it's whatever the default is.





Reply With Quote
Reply


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



© Camley Interactive (camley.info) 2008 - all logos and images are copywrite their respective owners.
Proud member of the Camley Interactive Network
All times are GMT. The time now is 03:02 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.
Inactive Reminders By Mished.co.uk