Re: Editing spanish language files [bayes SPAMTRAP]

2008-08-01 Thread Paul Hastings
Jeff Gladnick wrote:
 I have to edit some code that has a fair amount of spanish mixed in.  I've

ouch.

 tried every file type in eclipse, but it still doesn't appear right.  Spanish
 characters are replaced with crap, or vanish altogether.  Is there a specific

http://www.sustainablegis.com/blog/cfg11n/index.cfm?mode=entryentry=8B5D7DCB-20ED-7DEE-2AC2AD8DB7123EDE


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Resource Bundle editors

2008-08-01 Thread Bobby Hartsfield
Just wondering what others are using for editing resource bundles. I like
the Resource Bundle Editor plugin for eclipse very much
(http://sourceforge.net/projects/eclipse-rbe/ ) but it doesn't seem to work
with the latest version of Eclipse (3.4 Ganymede) and the website for the
plugin appears to be no more so I don't know if there are plans to update
it. I have to have a separate 'install' of eclipse 3.3.2 just for the
plugin. but 3.3.2 keeps crashing on me at work. (seems fine from home still)

 

So what are you guys (and gals) using?

 

..:.:.:.:.:.:.:.:.:.:.

Bobby Hartsfield

http://acoderslife.com

http://cf4em.com

 





~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Resource Bundle editors

2008-08-01 Thread Will Tomlinson
Just wondering what others are using for editing resource bundles. I like

I'm a newbie, but started using this one since I'm still not a cfeclipse user.

http://attesoro.org/

Will 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Resource Bundle editors [bayes SPAMTRAP]

2008-08-01 Thread Paul Hastings
Bobby Hartsfield wrote:
 Just wondering what others are using for editing resource bundles. I like
 the Resource Bundle Editor plugin for eclipse very much

be careful. it can save rb as utf-8 which while ok for flex isn't too good for 
java based rb which are expecting escaped unicode. i hate the darned thing.

 So what are you guys (and gals) using?

icu4j's rbManager is the grand daddy  what we use. attesoro's not too bad, i 
think the coldbox folks use that.


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: How do I extract Error Information from Structure?

2008-08-01 Thread Michael Brennan-White
Josh,

Thank you very much.  That got me going on the path to what I need to 
accomplish.  

Once again, thanks,

Michael

Here is a little function I use to send myself error messages - 
arguments.exc is the exception structure that the onError method receives - 
I pass it through to an Error.cfc.

cfsavecontent variable=content

   h2Error Report: #DateFormat(Now(),long)#, 
#TimeFormat(Now(),long)#/h2
   h3 style=color:red; id=errormessage#arguments.exc.message#/h3
   h4 style=color:blue; id=errorlocationThe error occurred in 
#arguments.exc.TagContext[1].template#/h4
   p id=errordetail#arguments.exc.detail#/p

!--- loop tagcontext to extract template and line information ---
   cfloop from=1 to=#ArrayLen(arguments.exc.TagContext)# index=i
   span id=tagcontext_#i##arguments.exc.TagContext[i].Template#, 
Line #arguments.exc.TagContext[i].Line#/spanbr
   /cfloop

/cfsavecontent

-- Josh


 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: (ot) Best FTP Software 4 Windows

2008-08-01 Thread Mike Chabot
I switched from Smart FTP to FileZilla as my primary FTP program a few
years back.

-Mike Chabot

On Wed, Jul 30, 2008 at 9:07 AM, Che Vilnonis [EMAIL PROTECTED] wrote:
 Just curious as to what y'all use. In the past I've used Smart FTP, but it
 has grown into 'bloatware' IMO and I'm looking to find something a bit more
 lightweight and free to use. Your thoughts?

 TIA, Che

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


2 questions: ensuring a file is only included once, and scrubbing form and url scopes

2008-08-01 Thread Pete Ruckelshaus
I've got two questions.

First: Is there a way to make sure a file is only cfincluded once?  I'm
using cfinclude to include a UDF library in the onRequestStart() method of
my application.cfc, but in my debug output, that file has a file count of 7,
which has led me to realize that it's also being included when all of the
other cfc and cfm files that go into the page are being called.

Second: What method/code do you use to scrub/trim values in the FORM and URL
scopes?

Thanks

Pete


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


RE: 2 questions: ensuring a file is only included once, and scrubbing form and url scopes

2008-08-01 Thread Dave Phillips
Pete:

1.  You could check for the existence of a variable (or function) in the
cfinclude, like this:

cfif NOT isDefined(var_name_from_include)
cfinclude template=whatever.cfm
/cfif

2.  There are some custom tags/udfs out there for this, but I haven't used
them.  I'd check CFLIB.ORG, or maybe someone else here can recommend
something specific.

Dave

-Original Message-
From: Pete Ruckelshaus [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2008 9:46 AM
To: CF-Talk
Subject: 2 questions: ensuring a file is only included once, and scrubbing
form and url scopes

I've got two questions.

First: Is there a way to make sure a file is only cfincluded once?  I'm
using cfinclude to include a UDF library in the onRequestStart() method of
my application.cfc, but in my debug output, that file has a file count of 7,
which has led me to realize that it's also being included when all of the
other cfc and cfm files that go into the page are being called.

Second: What method/code do you use to scrub/trim values in the FORM and URL
scopes?

Thanks

Pete




~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: 2 questions: ensuring a file is only included once, and scrubbing form and url scopes

2008-08-01 Thread Loathe
trim() to trim variables.


Pete Ruckelshaus wrote:
 I've got two questions.
 
 First: Is there a way to make sure a file is only cfincluded once?  I'm
 using cfinclude to include a UDF library in the onRequestStart() method of
 my application.cfc, but in my debug output, that file has a file count of 7,
 which has led me to realize that it's also being included when all of the
 other cfc and cfm files that go into the page are being called.
 
 Second: What method/code do you use to scrub/trim values in the FORM and URL
 scopes?
 
 Thanks
 
 Pete
 
 
 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: 2 questions: ensuring a file is only included once, and scrubbing form and url scopes

2008-08-01 Thread Justin Scott
 First: Is there a way to make sure a file is only
  cfincluded once?

You can set a special variable in the included file and check for it 
before including it anywhere to ensure it only gets loaded once no 
matter how many times you call it.  In the include:

cfset someSpecialVariable = 1

When you include that file:

cfif not isDefined(someSpecialVariable)
   cfinclude template=myInclude.cfm
/cfif

 Second: What method/code do you use to scrub/trim values in the
  FORM and URL scopes?

That depends on the type of data being passed in.  For general text 
fields a trim() will do the job, and you can combine that with other 
functions to ensure it won't cause a SQL truncation error.  For integer 
values I generally use:

cfset url.someID = min(abs(val(trim(url.someID))), 2147483647)

This guarantees a positive integer to prevent errors in a variety of places.


-Justin Scott


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: 2 questions: ensuring a file is only included once, and scrubbing form and url scopes

2008-08-01 Thread William Seiter
I try to use functions and CFCs for code that may need to be included more than 
once, but I can think of a quick fix if you need to mimic an 'include_once' 
process:
at the bottom of your include code create a new unique variable.  at the top of 
the include code add a cfif not isdefined('[unique variable]') around the 
entire code.

This way if the code is run once that variable now exists and won't be run 
again.

For the Trimming, I usually use trim(form.[varname]) when I need to remove 
leading and trailing spaces

William

 
--
William E. Seiter
ColdFusion Programmer / Web Developer

Free Website Trade Publication  Website Magazine
Be sure to answer all of the questions on the subscription form, small price to 
pay for the loads of excellent content this magazine offers to Web 
Professionals for FREE!!

Have you ever read a book that changed your life?
Go to: www.winninginthemargins.com
Use PassKey: GoldenGrove
You'll be glad you did.

I've got two questions.

First: Is there a way to make sure a file is only cfincluded once?  I'm
using cfinclude to include a UDF library in the onRequestStart() method of
my application.cfc, but in my debug output, that file has a file count of 7,
which has led me to realize that it's also being included when all of the
other cfc and cfm files that go into the page are being called.

Second: What method/code do you use to scrub/trim values in the FORM and URL
scopes?

Thanks

Pete 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: 2 questions: ensuring a file is only included once, and scrubbing form and url scopes

2008-08-01 Thread Yuliang Ruan
back in the days of C/C++ we used to do this with header files all the time.

inside the included file do:

cfif isdefined(include_myfile) is 0

cfset include_myfile=1

!-- do all your foos here ---

/cfif


that way you won't have to do cfif logic in the parent includer files. 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Chinese characters in CF

2008-08-01 Thread Nick Gleason
We have a client who wants our CF based application to display chinese
characters.  We've done a bit of research but haven't been able to pull it
off yet.  So, I wanted to see if others have figured that out and have any
words of advice to share.

Thanks!

Nick

.
..
 



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Editing spanish language files

2008-08-01 Thread Jeff Gladnick
Sorry - thats what i meant, encoding.  How do i check the encoding of the file?

-jeff


What's the encoding of the file? make sure that the file encoding is  
the same as the encoding in (CF)Eclipse.
Not sure what you mean with file type?

Cheers
Kai


 I have to edit some code that has a fair amount of spanish mixed  
 in.  I've tried every file type in eclipse, but it still doesn't  
 appear right.  Spanish characters are replaced with crap, or vanish  
 altogether.  Is there a specific file type I need to get? 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Chinese characters in CF

2008-08-01 Thread Yuliang Ruan
you'd be outputting unicode.   hopefully your client will have either big5 or 
gb font package installed already.

have fun coding error messages and whatnot in unicode. hehe  

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Odd cf7 sandbox issue

2008-08-01 Thread Casey C Cook
We have been able to isolate the issue to a specific server, then rebuild 
the sandbox to correct the issue. The problem is we dont know what is 
causing the issue, once it starts all users are affected until we rebuild 
the sandbox or the coldfusion service is restarted. Im going to start 
googling for answers, just thought I would touch base here as well.

access denied (java.io.FilePermission 
\\apfs\projects\web\production\inetpub\myapplication\my_template.cfm 
execute) null

Computer Sciences Corporation 
Registered Office: 3170 Fairview Park Drive, Falls Church, Virginia 22042, 
USA
Registered in Nevada, USA No: C-489-59

-
This is a PRIVATE message. If you are not the intended recipient, please 
delete without copying and kindly advise us by e-mail of the mistake in 
delivery. 
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to 
any order or other contract unless pursuant to explicit written agreement 
or government initiative expressly permitting the use of e-mail for such 
purpose.
-

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Checking if a date is within a date range

2008-08-01 Thread sstwebworks
Hey all. 

I've got a fiscal year that runs from July of a year to June of the next (July 
2008 to July 2009). In the body of the application that I'm runnng I have a 
list of categories that will change when the fiscal year changes.

I need to find out if now() falls in the current fiscal year and set a date 
variable that will be passed to a query to get the categories.

Does anyone have a code snippet that determines if a date falls in between two 
other dates?

Thanks

sas
--
Scott Stewart 
ColdFusion Developer 
http://www.sstwebworks.com/blog


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Fw: Odd cf7 sandbox issue

2008-08-01 Thread Casey C Cook
Now that I look closer at the issue, it seems to be a casing issue in the 
path trying to be accessed. Now to find out how the case is changing on a 
template call.

so it seems:

success
\\apfs\projects\web\production\inetpub\myapplication\my_template.cfm

failure
\\apfs\projects\web\production\inetpub\MYAPPLICATION\my_template.cfm

Computer Sciences Corporation 
Registered Office: 3170 Fairview Park Drive, Falls Church, Virginia 22042, 
USA
Registered in Nevada, USA No: C-489-59

-
This is a PRIVATE message. If you are not the intended recipient, please 
delete without copying and kindly advise us by e-mail of the mistake in 
delivery. 
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to 
any order or other contract unless pursuant to explicit written agreement 
or government initiative expressly permitting the use of e-mail for such 
purpose.
-

- Forwarded by Casey C Cook/GTS/CSC on 08/01/2008 10:52 AM -

Casey C Cook/GTS/[EMAIL PROTECTED] 
08/01/2008 10:19 AM
Please respond to
cf-talk@houseoffusion.com


To
CF-Talk cf-talk@houseoffusion.com
cc

Subject
Odd cf7 sandbox issue






We have been able to isolate the issue to a specific server, then rebuild 
the sandbox to correct the issue. The problem is we dont know what is 
causing the issue, once it starts all users are affected until we rebuild 
the sandbox or the coldfusion service is restarted. Im going to start 
googling for answers, just thought I would touch base here as well.

access denied (java.io.FilePermission 
\\apfs\projects\web\production\inetpub\myapplication\my_template.cfm 
execute) null

Computer Sciences Corporation 
Registered Office: 3170 Fairview Park Drive, Falls Church, Virginia 22042, 

USA
Registered in Nevada, USA No: C-489-59

-
This is a PRIVATE message. If you are not the intended recipient, please 
delete without copying and kindly advise us by e-mail of the mistake in 
delivery. 
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to 
any order or other contract unless pursuant to explicit written agreement 
or government initiative expressly permitting the use of e-mail for such 
purpose.
-



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Checking if a date is within a date range

2008-08-01 Thread Greg Morphis
if your database supports BETWEEN,
you can
select foo
from my_tbl
where my_date between start_date and end_date

or are you wanting to do that in ColdFusion?

On Fri, Aug 1, 2008 at 12:46 PM,  [EMAIL PROTECTED] wrote:
 Hey all.

 I've got a fiscal year that runs from July of a year to June of the next 
 (July 2008 to July 2009). In the body of the application that I'm runnng I 
 have a list of categories that will change when the fiscal year changes.

 I need to find out if now() falls in the current fiscal year and set a date 
 variable that will be passed to a query to get the categories.

 Does anyone have a code snippet that determines if a date falls in between 
 two other dates?

 Thanks

 sas
 --
 Scott Stewart
 ColdFusion Developer
 http://www.sstwebworks.com/blog


 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Checking if a date is within a date range

2008-08-01 Thread Greg Morphis
If you're wanting coldfusion to check, you could do something like:

cfset mydate = now() /
cfset sDate = CreateDate(year(now()),7,1) /
cfset eDate = CreateDate(year(now())+1,7,1) /

cfoutput
sdate = #sdate#br /
edate = #edate#br /
/cfoutput
cfif mydate gte sdate and mydate lt edate
It's therebr /
cfelse
Nopebr /
/cfif



On Fri, Aug 1, 2008 at 12:58 PM, Greg Morphis [EMAIL PROTECTED] wrote:
 if your database supports BETWEEN,
 you can
 select foo
 from my_tbl
 where my_date between start_date and end_date

 or are you wanting to do that in ColdFusion?

 On Fri, Aug 1, 2008 at 12:46 PM,  [EMAIL PROTECTED] wrote:
 Hey all.

 I've got a fiscal year that runs from July of a year to June of the next 
 (July 2008 to July 2009). In the body of the application that I'm runnng I 
 have a list of categories that will change when the fiscal year changes.

 I need to find out if now() falls in the current fiscal year and set a date 
 variable that will be passed to a query to get the categories.

 Does anyone have a code snippet that determines if a date falls in between 
 two other dates?

 Thanks

 sas
 --
 Scott Stewart
 ColdFusion Developer
 http://www.sstwebworks.com/blog


 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Checking if a date is within a date range

2008-08-01 Thread sstwebworks
It does (MSSQLServer 2000) I think I've got it handled this way:

!--- determines if today is within the current fiscal year 
  Author: Scott Stewart, Procomm 
  Date: 08/01/2008
  Comments: UDF taken from CFLIB.org
 ---
cfscript
 /**
 * Returns True if the date provided in the first argument lies between the two 
dates in the second and third arguments.
 * 
 * @param dateObj  CF 
 */
 function IsDateBetween(dateObj, dateCompared1, dateCompared2){
  return YesNoFormat((DateCompare(dateObj, dateCompared1) gt -1) AND 
(DateCompare(dateObj, dateCompared2) lt 1));
 }
/cfscript
cfset startYear = #datePart(, now())#
cfset endYear = #datePart(, now())# +1

cfset fyYearStart = '6/01/#datePart(, now())#'
cfset fyYearEnd = '7/01/#endYear#'

cfif (IsDateBetween(Now(),#fyYearStart#,#fyYearEnd#) is yes)
 cfset application.cat_date = #datePart(, now())# +1
/cfif
!--- end ---

The application.cat_date becomes the year parameter that's passed to the query 
that retrieves the categories.

--
Scott Stewart 
ColdFusion Developer 
http://www.sstwebworks.com/blog

-- Original message from Greg Morphis [EMAIL PROTECTED]: 
-- 


 if your database supports BETWEEN, 
 you can 
 select foo 
 from my_tbl 
 where my_date between start_date and end_date 
 
 or are you wanting to do that in ColdFusion? 
 
 On Fri, Aug 1, 2008 at 12:46 PM, wrote: 
  Hey all. 
   I've got a fiscal year that runs from July of a year to June of the next 
   (July 2008 to July 2009). In the body of the application that I'm runnng 
   I have a list 
 of categories that will change when the fiscal year changes. 
   I need to find out if now() falls in the current fiscal year and set a 
   date 
 variable that will be passed to a query to get the categories. 
   Does anyone have a code snippet that determines if a date falls in 
   between two 
 other dates? 
  
  Thanks 
  
  sas 
  -- 
  Scott Stewart 
  ColdFusion Developer 
  http://www.sstwebworks.com/blog 
  
  
  
 
 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


RE: Resource Bundle editors [bayes SPAMTRAP]

2008-08-01 Thread Bobby Hartsfield
Great I'll check into those. I am working with Java resource bundles by the

way. 

From what I've seen with the Eclipse plugin, you can type/paste/view the
characters on the editor side just fine but when you view the files, they
are all escaped. You can change the prefs to either convert or not convert
as well.

For example, if you put the ñ character in through the editor, (I forget
what it is called... and not sure how it will display here but it is the n
with the tilde over it... alt + 164) it displays fine and when you actually
view the contents of the files, it is \u00F1

Is that what you mean when you say that Java expects them to be escaped?

..:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com
http://cf4em.com

-Original Message-
From: Paul Hastings [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2008 9:23 AM
To: CF-Talk
Subject: Re: Resource Bundle editors [bayes SPAMTRAP]

Bobby Hartsfield wrote:
 Just wondering what others are using for editing resource bundles. I like
 the Resource Bundle Editor plugin for eclipse very much

be careful. it can save rb as utf-8 which while ok for flex isn't too good
for 
java based rb which are expecting escaped unicode. i hate the darned thing.

 So what are you guys (and gals) using?

icu4j's rbManager is the grand daddy  what we use. attesoro's not too bad,
i 
think the coldbox folks use that.




~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Chinese characters in CF

2008-08-01 Thread Randy Messer
We have a client who wants our CF based application to display chinese
characters.  We've done a bit of research but haven't been able to pull it
off yet.  So, I wanted to see if others have figured that out and have any
words of advice to share.

Thanks!

Nick


.

For What's Its Worth. We have application requiring different languages 
dependent upon users login. In my situation I built an admin interface listing 
all phrases that needed to be translated. Translators login and post translated 
phrases. Action inserts to Db and writes a cfm file. Set up folders for Eng, 
JP, Sp, etc. For output, to avoid qry each phrase, instead I read the files 
based on session language var required for page and set as var for output. I 
also set a session var for the charset, UTF-8, or Shift_JIS for Japanese. Once 
you have the initial set up, you can add languages with ease. Don't know how 
this sounds to others, but it works like a charm. 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


RE: Chinese characters in CF

2008-08-01 Thread Ben Forta
I did something similar for CFFAQ. It supports all sorts of languages,
including Chinese and Urdu (a right-to-left language).

Default:http://www.cffaq.com/
Chinese:http://www.cffaq.com/index.cfm?language=cn
Urdu:   http://www.cffaq.com/index.cfm?language=ur
Russian:http://www.cffaq.com/index.cfm?language=ru
 and so on.

All data is stored in SQL Server in N data type fields. And UTF-8 is used
for all CF pages. The rest just kinda works.

All strings, and I do mean every single string, is in a massive externalized
string table. And there is an entire admin interface for defining new
strings, and then for translators to be presented with strings and to be
able to save translations.

Works beautifully!

(Now if the site was ever updated ...)

--- Ben


-Original Message-
From: Randy Messer [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2008 4:41 PM
To: CF-Talk
Subject: Re: Chinese characters in CF

We have a client who wants our CF based application to display chinese
characters.  We've done a bit of research but haven't been able to pull it
off yet.  So, I wanted to see if others have figured that out and have any
words of advice to share.

Thanks!

Nick

...
..
.

For What's Its Worth. We have application requiring different languages
dependent upon users login. In my situation I built an admin interface
listing all phrases that needed to be translated. Translators login and post
translated phrases. Action inserts to Db and writes a cfm file. Set up
folders for Eng, JP, Sp, etc. For output, to avoid qry each phrase, instead
I read the files based on session language var required for page and set as
var for output. I also set a session var for the charset, UTF-8, or
Shift_JIS for Japanese. Once you have the initial set up, you can add
languages with ease. Don't know how this sounds to others, but it works like
a charm. 



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Binary File

2008-08-01 Thread Brian Peddle
I have an Adobe Air application that will post a file to a cfc. 

The cfc accepts the file fine.

cfargument name=foo type=binary required=yes   

 and I can process it and actually post to another web service for 
processing.  Doing this in the xml

DocumentAsByteArray#ToBase64(arguments.foo)#/DocumentAsByteArray

Is it possible to determine the file name and mime type when accepting a 
binary file like this?  File type could be .doc, .pdf etc



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Chinese characters in CF

2008-08-01 Thread Paul Hastings
Nick Gleason wrote:
 We have a client who wants our CF based application to display chinese
 characters.  We've done a bit of research but haven't been able to pull it
 off yet.  So, I wanted to see if others have figured that out and have any
 words of advice to share.

i guess the first thing you should do is find out what 'chinese' *they* mean by 
'chinese'.

- for encoding: just use unicode
- for the strings: use resource bundles, it's the way it's done in java since 
forever so there's a whole environment to manage these. there was a question on 
the list regarding this recently.
- don't forget date, etc. formatting also needs to be handled.
- do they want to use the gregorian calendar or a chinese one?

read these:

http://www.adobe.com/devnet/coldfusion/articles/globalize.html
http://www.sustainablegis.com/blog/cfg11n/index.cfm?mode=catcatid=6D990B76-50FC-543B-1FA4AB2B1CE26EFC
the g11n chapter in ben's cf books.


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Resource Bundle editors [bayes SPAMTRAP] [bayes SPAMTRAP]

2008-08-01 Thread Paul Hastings
Bobby Hartsfield wrote:

From what I've seen with the Eclipse plugin, you can type/paste/view the
 characters on the editor side just fine but when you view the files, they
 are all escaped. You can change the prefs to either convert or not convert
 as well.

the last version i looked at had the option (maybe was default) to save as 
utf-8 
encoded files. if i recall correctly, somebody blew up a set of rb i had built 
(using rbManager) with it. if you've ever made an existing app i18n, you know 
how dreary a job creating rb is, so anything that even has the chance of 
breaking that just plain sucks in my opinion.

 view the contents of the files, it is \u00F1
 
 Is that what you mean when you say that Java expects them to be escaped?

yup. makes them highly portable (or it's just how it was done once  now it's 
too late to change ;-).

btw i forgot to mention that rbManager has fairly extensive management 
functionality for trackng what's been translated, by whom, when, etc. as well 
as 
a reporting tool which helps on large/complex projects. and i just looked at 
attesoro's site  most of his complaints against rbManager involves importing 
other rb into it (because of the fairly extensive management functionality).


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Chinese characters in CF

2008-08-01 Thread Paul Hastings
Randy Messer wrote:

 Don't know how this sounds to others, but it works like a charm.

it sounds like re-inventing the wheel to me ;-)


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


Re: Resource Bundle editors [bayes SPAMTRAP] [bayes SPAMTRAP]

2008-08-01 Thread Paul Hastings
oops, i forgot that jason sheedy's also got an rb management tool:

http://www.jmpj.net/jason/page.cfm/RbMan2

it's flex based so it won't right now handle RTL (arabic, hebrew, etc.).

he also has a pure cf based one:

http://www.jmpj.net/rbman/

but i think he ditched that for the flex version.


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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


RE: Resource Bundle editors [bayes SPAMTRAP] [bayes SPAMTRAP]

2008-08-01 Thread Bobby Hartsfield
 if you've ever made an existing app i18n, you know 
 how dreary a job creating rb is

Nope, this is my first true i18n venture and I was actually planning to look
you up again soon :-)

But I do know what you mean about dreary. I am actually converting the
format of existing files now ...which is no less dreary than creating them
from scratch... believe me 

 yup. makes them highly portable

Perfect!

..:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com
http://cf4em.com

-Original Message-
From: Paul Hastings [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2008 7:48 PM
To: CF-Talk
Subject: Re: Resource Bundle editors [bayes SPAMTRAP] [bayes SPAMTRAP]

Bobby Hartsfield wrote:

From what I've seen with the Eclipse plugin, you can type/paste/view the
 characters on the editor side just fine but when you view the files, they
 are all escaped. You can change the prefs to either convert or not convert
 as well.

the last version i looked at had the option (maybe was default) to save as
utf-8 
encoded files. if i recall correctly, somebody blew up a set of rb i had
built 
(using rbManager) with it. if you've ever made an existing app i18n, you
know 
how dreary a job creating rb is, so anything that even has the chance of 
breaking that just plain sucks in my opinion.

 view the contents of the files, it is \u00F1
 
 Is that what you mean when you say that Java expects them to be escaped?

yup. makes them highly portable (or it's just how it was done once  now
it's 
too late to change ;-).

btw i forgot to mention that rbManager has fairly extensive management 
functionality for trackng what's been translated, by whom, when, etc. as
well as 
a reporting tool which helps on large/complex projects. and i just looked at

attesoro's site  most of his complaints against rbManager involves
importing 
other rb into it (because of the fairly extensive management
functionality).




~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

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