Where you one put encoding hints in an Application.cfc?

2006-08-28 Thread Ian Skinner
Where would one put encoding hints like these in an Application.cfc file.

!--- Set encoding hints for processing special characters. ---
cfprocessingdirective pageencoding=windows-1252 /
cfset setEncoding(form,windows-1252) /
cfset setEncoding(url,windows-1252) /
cfcontent type=text/html; charset=windows-1252 reset=yes /

My first guess would be onRequestStart, but is there a better place, and if so, 
why?


--
Ian Skinner
Web Programmer
BloodSource
www.BloodSource.org
Sacramento, CA

-
| 1 |   |
-  Binary Soduko
|   |   |
-
 
C code. C code run. Run code run. Please!
- Cynthia Dunning

Confidentiality Notice:  This message including any
attachments is for the sole use of the intended
recipient(s) and may contain confidential and privileged
information. Any unauthorized review, use, disclosure or
distribution is prohibited. If you are not the
intended recipient, please contact the sender and
delete any copies of this message. 



~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:251261
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


RE: Where you one put encoding hints in an Application.cfc?

2006-08-28 Thread Andy Matthews
Why not put it in onApplicationStart?

!//--
andy matthews
web developer
certified advanced coldfusion programmer
ICGLink, Inc.
[EMAIL PROTECTED]
615.370.1530 x737
--//-

-Original Message-
From: Ian Skinner [mailto:[EMAIL PROTECTED]
Sent: Monday, August 28, 2006 11:27 AM
To: CF-Talk
Subject: Where you one put encoding hints in an Application.cfc?


Where would one put encoding hints like these in an Application.cfc file.

!--- Set encoding hints for processing special characters. ---
cfprocessingdirective pageencoding=windows-1252 /
cfset setEncoding(form,windows-1252) /
cfset setEncoding(url,windows-1252) /
cfcontent type=text/html; charset=windows-1252 reset=yes /

My first guess would be onRequestStart, but is there a better place, and if
so, why?


~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:251263
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: Where you one put encoding hints in an Application.cfc?

2006-08-28 Thread Ian Skinner
Why not put it in onApplicationStart?


Well, I'm not sure why not, which is why I asked the question.  

My thinking was that these encoding hints need to run every request, they 
aren't something that would be automatically remembered are they?  Thus if they 
where in the application start, they would run once for that request and then 
be forgotten. 

But I'm not sure on this, so I was hopping to get some perspective from better 
minds then mine.


--
Ian Skinner
Web Programmer
BloodSource
www.BloodSource.org
Sacramento, CA

-
| 1 |   |
-  Binary Soduko
|   |   |
-
 
C code. C code run. Run code run. Please!
- Cynthia Dunning

Confidentiality Notice:  This message including any
attachments is for the sole use of the intended
recipient(s) and may contain confidential and privileged
information. Any unauthorized review, use, disclosure or
distribution is prohibited. If you are not the
intended recipient, please contact the sender and
delete any copies of this message. 




~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:251264
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Where you one put encoding hints in an Application.cfc?

2006-08-28 Thread Paul Hastings
Ian Skinner wrote:
 Where would one put encoding hints like these in an Application.cfc file.
 
 !--- Set encoding hints for processing special characters. ---
 cfprocessingdirective pageencoding=windows-1252 /

you can't use cfprocessingdirective in application.cfm  i guess 
application.cfc. it's a compile time tag (also why you can't use 
conditional logic with it).

 cfset setEncoding(form,windows-1252) /
 cfset setEncoding(url,windows-1252) /
 cfcontent type=text/html; charset=windows-1252 reset=yes /

these are fine.


~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:251269
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


RE: Where you one put encoding hints in an Application.cfc?

2006-08-28 Thread Ian Skinner
quote
Why not just put it in the application constructor (the space in the .cfc 
component tags outside of functions)... The Application.cfc get created every 
page call (as far as I know). Except the cfcontent tag, you probably would 
want to put after  most of the pre-page-processing as you are resetting the 
buffer (take advantage of that later in the game).

Also, I have little encoding experience... What is the use of setting it?
/quote

That sounds like an interesting idea Ben.  I will give it a try.  

The purpose of encoding is to change the encoding of the page.  In my case, so 
this application can understand special word characters when they are pasted 
into a form.




--
Ian Skinner
Web Programmer
BloodSource
www.BloodSource.org
Sacramento, CA

-
| 1 |   |
-  Binary Soduko
|   |   |
-
 
C code. C code run. Run code run. Please!
- Cynthia Dunning

Confidentiality Notice:  This message including any
attachments is for the sole use of the intended
recipient(s) and may contain confidential and privileged
information. Any unauthorized review, use, disclosure or
distribution is prohibited. If you are not the
intended recipient, please contact the sender and
delete any copies of this message. 




~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:251276
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4