RE: Capturing Mac's SmartQuotes

2005-02-14 Thread Matthew Small
I *believe* that it does, but I have not tried it for the PC, only on Mac.
However, the Mac's Smart Quotes did come from MS Word (Mac).

- Matt Small

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 14, 2005 10:46 AM
To: CF-Talk
Subject: RE: Capturing Mac's SmartQuotes

Does this follow for MS Word Smart quotes also?

sas

Scott A. Stewart, 
Web Application Developer
 
Engineering Consulting Services, Ltd. (ECS)
14026 Thunderbolt Place, Suite 100
Chantilly, VA 20151
Phone: (703) 471-8400
Fax: (703) 834-5527


-Original Message-
From: Matthew Small [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 14, 2005 09:51 am
To: CF-Talk
Subject: RE: Capturing Mac's SmartQuotes

Hi Talk,

I figured out that the smart quotes have a very high ASCII code.  Here's
what I did to remove them:

function RemoveSmartQuotes (st) {
st = replace(st, chr(8220), chr(34), "all");
st = replace(st, chr(8221), chr(34), "all");
st = replace(st, chr(8216), chr(39), "all");
st = replace(st, chr(8217), chr(39), "all");

return st;
}


I thought you'd like to know.

- Matt Small







~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194553
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


Re: Capturing Mac's SmartQuotes

2005-02-14 Thread Spike
FYI,

The smart quotes are not limited to Mac only.

There's a useful reference page about them and other high ascii 
characters here:

http://www.cs.tut.fi/%7Ejkorpela/www/windows-chars.html#list

For the project I'm working on at the minute I have customized jTidy to 
take care of these and emit the correct HTML entity codes in the 
generated HTML.

By default jTidy replaces the high ascii values with HTML entities, but 
the resulting output fails XHTML strict validation. I don't remember off 
the top of my head exactly what jTidy outputs, but the entities on the 
page linked above pass the validation test.

Spike

[EMAIL PROTECTED] wrote:
> Does this follow for MS Word Smart quotes also?
> 
> sas
> 
> Scott A. Stewart, 
> Web Application Developer
>  
> Engineering Consulting Services, Ltd. (ECS)
> 14026 Thunderbolt Place, Suite 100
> Chantilly, VA 20151
> Phone: (703) 471-8400
> Fax: (703) 834-5527
> 
> 
> -Original Message-
> From: Matthew Small [mailto:[EMAIL PROTECTED] 
> Sent: Monday, February 14, 2005 09:51 am
> To: CF-Talk
> Subject: RE: Capturing Mac's SmartQuotes
> 
> Hi Talk,
> 
> I figured out that the smart quotes have a very high ASCII code.  Here's
> what I did to remove them:
> 
> function RemoveSmartQuotes (st) {
>   st = replace(st, chr(8220), chr(34), "all");
>   st = replace(st, chr(8221), chr(34), "all");
>   st = replace(st, chr(8216), chr(39), "all");
>   st = replace(st, chr(8217), chr(39), "all");
>   
>   return st;
> }
> 
> 
> I thought you'd like to know.
> 
> - Matt Small
> 
> 
> 
> 
> 
> 

~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194552
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Capturing Mac's SmartQuotes

2005-02-14 Thread SStewart
Does this follow for MS Word Smart quotes also?

sas

Scott A. Stewart, 
Web Application Developer
 
Engineering Consulting Services, Ltd. (ECS)
14026 Thunderbolt Place, Suite 100
Chantilly, VA 20151
Phone: (703) 471-8400
Fax: (703) 834-5527


-Original Message-
From: Matthew Small [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 14, 2005 09:51 am
To: CF-Talk
Subject: RE: Capturing Mac's SmartQuotes

Hi Talk,

I figured out that the smart quotes have a very high ASCII code.  Here's
what I did to remove them:

function RemoveSmartQuotes (st) {
st = replace(st, chr(8220), chr(34), "all");
st = replace(st, chr(8221), chr(34), "all");
st = replace(st, chr(8216), chr(39), "all");
st = replace(st, chr(8217), chr(39), "all");

return st;
}


I thought you'd like to know.

- Matt Small





~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194528
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Capturing Mac's SmartQuotes

2005-02-14 Thread Matthew Small
Hi Talk,

I figured out that the smart quotes have a very high ASCII code.  Here's
what I did to remove them:

function RemoveSmartQuotes (st) {
st = replace(st, chr(8220), chr(34), "all");
st = replace(st, chr(8221), chr(34), "all");
st = replace(st, chr(8216), chr(39), "all");
st = replace(st, chr(8217), chr(39), "all");

return st;
}


I thought you'd like to know.

- Matt Small



~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194526
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


Re: Capturing Mac's SmartQuotes

2005-02-10 Thread Ben Doom
Since a Uinicode char is just two bytes, if you can find out what two 
byte values they represent, you can still replace them.

Assuming they're 142 and 143:
replace(text, chr(142)&chr(143), '"', 'all');

Try just using asc() to get the values.

HTH

--Ben

Matthew Small wrote:
> Hi,
> 
> One of my users pastes text into a form from his Mac word
> processor.  Quite frequently, the document contains "smart quotes" - curly
> quotes that go on each end of a string.  Apparently, some PCs have issues
> displaying these characters, so I need to know how to convert them to
> straight normal quotes.
> 
> I am under the impression that these are Unicode characters as
> opposed to ASCII characters.  As such, I am unsure how to do a replace in CF
> - MX 6.1. I've looked in the livedocs but I don't see a function that works
> like chr() for Unicode.  What am I missing here?
> 
>  
> 
> Thank you,
> 
> Matthew Small
> 
> 
> 
> 

~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194053
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Capturing Mac's SmartQuotes

2005-02-10 Thread Martin Parry
Sorry, that's all I have - maybe someone else has another solution but
this is extremely quick and "it works" :)

Martin Parry
Macromedia Certified Developer
http://www.BeetrootStreet.co.uk


-Original Message-
From: Matthew Small [mailto:[EMAIL PROTECTED] 
Sent: 10 February 2005 14:03
To: CF-Talk
Subject: RE: Capturing Mac's SmartQuotes

Thank you for responding.  I notice that this involves java calls - is
there
no native CF function that does this?

Thank you,
Matthew Small


~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194047
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Capturing Mac's SmartQuotes

2005-02-10 Thread Martin Parry
Sorry, that's all I have - maybe someone else has another solution but
this is extremely quick and "it works" :)

Martin Parry
Macromedia Certified Developer
http://www.BeetrootStreet.co.uk


-Original Message-
From: Matthew Small [mailto:[EMAIL PROTECTED] 
Sent: 10 February 2005 14:03
To: CF-Talk
Subject: RE: Capturing Mac's SmartQuotes

Thank you for responding.  I notice that this involves java calls - is
there
no native CF function that does this?

Thank you,
Matthew Small

-Original Message-
From: Martin Parry [mailto:[EMAIL PROTECTED] 
Sent: Thursday, February 10, 2005 8:36 AM
To: CF-Talk
Subject: RE: Capturing Mac's SmartQuotes

How about this - found it the other day while trying to solve a similair
thing where verity wasn't indexing TM signs so I needed to convert them
to normal HTML codes.




























Martin Parry
Macromedia Certified Developer
http://www.BeetrootStreet.co.uk


-Original Message-
From: Matthew Small [mailto:[EMAIL PROTECTED] 
Sent: 10 February 2005 13:24
To: CF-Talk
Subject: Capturing Mac's SmartQuotes

Hi,

One of my users pastes text into a form from his Mac word
processor.  Quite frequently, the document contains "smart quotes" -
curly
quotes that go on each end of a string.  Apparently, some PCs have
issues
displaying these characters, so I need to know how to convert them to
straight normal quotes.

I am under the impression that these are Unicode characters
as
opposed to ASCII characters.  As such, I am unsure how to do a replace
in CF
- MX 6.1. I've looked in the livedocs but I don't see a function that
works
like chr() for Unicode.  What am I missing here?

 

Thank you,

Matthew Small









~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194043
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Capturing Mac's SmartQuotes

2005-02-10 Thread Matthew Small
Thank you for responding.  I notice that this involves java calls - is there
no native CF function that does this?

Thank you,
Matthew Small

-Original Message-
From: Martin Parry [mailto:[EMAIL PROTECTED] 
Sent: Thursday, February 10, 2005 8:36 AM
To: CF-Talk
Subject: RE: Capturing Mac's SmartQuotes

How about this - found it the other day while trying to solve a similair
thing where verity wasn't indexing TM signs so I needed to convert them
to normal HTML codes.




























Martin Parry
Macromedia Certified Developer
http://www.BeetrootStreet.co.uk


-Original Message-
From: Matthew Small [mailto:[EMAIL PROTECTED] 
Sent: 10 February 2005 13:24
To: CF-Talk
Subject: Capturing Mac's SmartQuotes

Hi,

One of my users pastes text into a form from his Mac word
processor.  Quite frequently, the document contains "smart quotes" -
curly
quotes that go on each end of a string.  Apparently, some PCs have
issues
displaying these characters, so I need to know how to convert them to
straight normal quotes.

I am under the impression that these are Unicode characters
as
opposed to ASCII characters.  As such, I am unsure how to do a replace
in CF
- MX 6.1. I've looked in the livedocs but I don't see a function that
works
like chr() for Unicode.  What am I missing here?

 

Thank you,

Matthew Small







~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194041
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


RE: Capturing Mac's SmartQuotes

2005-02-10 Thread Martin Parry
How about this - found it the other day while trying to solve a similair
thing where verity wasn't indexing TM signs so I needed to convert them
to normal HTML codes.




























Martin Parry
Macromedia Certified Developer
http://www.BeetrootStreet.co.uk


-Original Message-
From: Matthew Small [mailto:[EMAIL PROTECTED] 
Sent: 10 February 2005 13:24
To: CF-Talk
Subject: Capturing Mac's SmartQuotes

Hi,

One of my users pastes text into a form from his Mac word
processor.  Quite frequently, the document contains "smart quotes" -
curly
quotes that go on each end of a string.  Apparently, some PCs have
issues
displaying these characters, so I need to know how to convert them to
straight normal quotes.

I am under the impression that these are Unicode characters
as
opposed to ASCII characters.  As such, I am unsure how to do a replace
in CF
- MX 6.1. I've looked in the livedocs but I don't see a function that
works
like chr() for Unicode.  What am I missing here?

 

Thank you,

Matthew Small





~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194035
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54


Capturing Mac's SmartQuotes

2005-02-10 Thread Matthew Small
Hi,

One of my users pastes text into a form from his Mac word
processor.  Quite frequently, the document contains "smart quotes" - curly
quotes that go on each end of a string.  Apparently, some PCs have issues
displaying these characters, so I need to know how to convert them to
straight normal quotes.

I am under the impression that these are Unicode characters as
opposed to ASCII characters.  As such, I am unsure how to do a replace in CF
- MX 6.1. I've looked in the livedocs but I don't see a function that works
like chr() for Unicode.  What am I missing here?

 

Thank you,

Matthew Small



~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194030
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54