Oracle 11g Upgrade Unable to select from CLOB datatype
We have just upgraded from Oracle 10g to 11g. Now we have an application that will not select from clob datatype column. We are getting the following error: Error Executing Database Query. [Macromedia][Oracle JDBC Driver]No more data available to read. The error occurred in E:\Collab\iweb\webapps\admin\Test\drivertest.cfm: line 1 1 : cfquery name=getTXT datasource=prod 2 : select 3 : ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338838 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Oracle 11g Upgrade Unable to select from CLOB datatype
Which version of CF are you using? -- WSS4CF - WS-Security framework for CF http://wss4cf.riaforge.org/ On 5 November 2010 15:50, Noveta Wimbley noveta.wimb...@sjcd.edu wrote: We have just upgraded from Oracle 10g to 11g. Now we have an application that will not select from clob datatype column. We are getting the following error: Error Executing Database Query. [Macromedia][Oracle JDBC Driver]No more data available to read. The error occurred in E:\Collab\iweb\webapps\admin\Test\drivertest.cfm: line 1 1 : cfquery name=getTXT datasource=prod 2 : select 3 : ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338839 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Back to .NET integration - Enumeration issue
Hi all, I'm back working with the Aspose .NET ddls and have a question. First I do this: cfobject type=.NET name=presentation class=Aspose.Slides.Presentation assembly=#slidesDLL# cfset presentation.init(#pptFile#) Now in order to save this presentation in another format the docs state that I need to do call the Save method of the Presentation class. It accepts two parameters, a string describing the file location, the second is constant described by this class: C# public enum SaveFormat Members Member Name Description Value Ppt Save presentation in PPT format.0 Pps Save presentation in PPS format.0 Pdf Save presentation in PDF format.1 Xps Save presentation in XPS format.2 PptxSave presentation in PPTX format. 3 PpsxSave presentation in PPSX format. 4 TiffSave presentation as multi-page TIFF image. 5 Question: How do I use this in CF? I've tried the following: cfset p = presentation.Save(#clientdir#/#uniqueID#.pdf, Pdf) and cfset p = presentation.Save(#clientdir#/#uniqueID#.pdf, 1) but both throw errors: The Save method was not found. Either there are no methods with the specified method name and argument types or the Save method is overloaded with argument types that ColdFusion cannot decipher reliably. ColdFusion found 0 methods that match the provided arguments. If I dump an instance of the SaveFormat class I see this: Field Value Aspose.Slides.Export.SaveFormat Pdf Aspose.Slides.Export.SaveFormat Aspose.Slides.Export.SaveFormat Pps Aspose.Slides.Export.SaveFormat Aspose.Slides.Export.SaveFormat PpsxAspose.Slides.Export.SaveFormat Aspose.Slides.Export.SaveFormat Ppt Aspose.Slides.Export.SaveFormat Aspose.Slides.Export.SaveFormat PptxAspose.Slides.Export.SaveFormat Aspose.Slides.Export.SaveFormat TiffAspose.Slides.Export.SaveFormat Aspose.Slides.Export.SaveFormat Xps Aspose.Slides.Export.SaveFormat Any tips appreciated. Stefan ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338840 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
If the documentation can be believed: http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=dotNet_04.html ...enumerator elements can be accessed directly by using the format Enumerator_variable.enumerator, as in MyColor.Red So try grabbing a reference to the Aspose.Slides.Export.SaveFormat. Then use: YourReference.Pdf -Leigh ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338841 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
So try grabbing a reference to the Aspose.Slides.Export.SaveFormat. Then use: YourReference.Pdf Awesome, that worked! Many thanks. I now only need to figure out how to convert/cast a .NET instance of System.Drawing.Bitmap to something I can save in CF as a JPG or similar. Cheers Stefan ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338842 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
Many thanks. I now only need to figure out how to convert/cast a .NET instance of System.Drawing.Bitmap to something I can save in CF as a JPG or similar. http://msdn.microsoft.com/en-us/library/system.drawing.image.save%28VS.80%29.aspx Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338843 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
Thanks Dave but how do I do this in CF? When I dump the object of type System.Drawing.Bitmap it does not show me a Save method. I'm not a backend programmer and C# is pretty alien to me. I understand this would all be much simpler in pure C# I guess but I feel I'm close now, all that's left is to somehow save the C# Bitmap to an image... Any pointers much appreciated. Stefan Class Name System.Drawing.Bitmap Methods Method Return Type Clone(System.Drawing.RectangleF, System.Drawing.Imaging.PixelFormat) System.Drawing.Bitmap Clone(System.Drawing.Rectangle, System.Drawing.Imaging.PixelFormat) System.Drawing.Bitmap FromHicon(System.IntPtr)System.Drawing.Bitmap FromResource(System.IntPtr, java.lang.String) System.Drawing.Bitmap GetHbitmap(System.Drawing.Color)System.IntPtr GetHbitmap()System.IntPtr GetHicon() System.IntPtr GetPixel(int, int) System.Drawing.Color LockBits(System.Drawing.Rectangle, System.Drawing.Imaging.ImageLockMode, System.Drawing.Imaging.PixelFormat, System.Drawing.Imaging.BitmapData) System.Drawing.Imaging.BitmapData LockBits(System.Drawing.Rectangle, System.Drawing.Imaging.ImageLockMode, System.Drawing.Imaging.PixelFormat)System.Drawing.Imaging.BitmapData MakeTransparent() void MakeTransparent(System.Drawing.Color) void SetPixel(int, int, System.Drawing.Color)void SetResolution(float, float) void UnlockBits(System.Drawing.Imaging.BitmapData) void http://msdn.microsoft.com/en-us/library/system.drawing.image.save%28VS. 80%29.aspx ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338844 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Oracle 11g Upgrade Unable to select from CLOB datatype
CF8 -Original Message- From: James Holmes [mailto:james.hol...@gmail.com] Sent: Friday, November 05, 2010 7:31 AM To: cf-talk Subject: Re: Oracle 11g Upgrade Unable to select from CLOB datatype Which version of CF are you using? -- WSS4CF - WS-Security framework for CF http://wss4cf.riaforge.org/ On 5 November 2010 15:50, Noveta Wimbley noveta.wimb...@sjcd.edu wrote: We have just upgraded from Oracle 10g to 11g. Now we have an application that will not select from clob datatype column. We are getting the following error: Error Executing Database Query. [Macromedia][Oracle JDBC Driver]No more data available to read. The error occurred in E:\Collab\iweb\webapps\admin\Test\drivertest.cfm: line 1 1 : cfquery name=getTXT datasource=prod 2 : select 3 : ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338845 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
When I dump the object of type System.Drawing.Bitmap it does not show me a Save method. Nevertheless, it should be in there. Image is an abstract class from which Bitmap is descended. I suspect that CFDUMP doesn't show you the methods of this abstract parent. I'm not a backend programmer and C# is pretty alien to me. I understand this would all be much simpler in pure C# I guess but I feel I'm close now, all that's left is to somehow save the C# Bitmap to an image... C# is actually a lot like AS3. And yeah, it's kind of hard to pick out pieces of C# to execute from CF, which is why I generally like to write a C# wrapper that does all of the intermediate steps I need to do, then call that wrapper from CF. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338846 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
Thanks again. Do you know how to instantiate System ddls? I keep getting errors when I try either cfobject type=.NET name=image class=System.Drawing.Image assembly=C:\Windows\Microsoft.NET\Framework\v4.0.30319\System.Drawing.dll or cfobject type=.NET name=image class=System.Drawing.Image Class System.Drawing.Image not found in the specified assembly list. Cheers Stefan ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338847 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
BTW you were right, I can call Save() on Bitmap :-) Thanks! ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338848 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
Do you know how to instantiate System ddls? I keep getting errors when I try either cfobject type=.NET name=image class=System.Drawing.Image assembly=C:\Windows\Microsoft.NET\Framework\v4.0.30319\System.Drawing.dll or cfobject type=.NET name=image class=System.Drawing.Image Class System.Drawing.Image not found in the specified assembly list. You can't instantiate an abstract class. Think of Image as being somewhat analogous to an interface in AS3. But in general, if you have a non-abstract class in System.*, you should be able to instantiate it without specifying an assembly path as it'll be in the Global Assembly Cache. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338849 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
Well as Dave said, System.Drawing.Bitmap descends from System.Drawing.Image. So it should have access to everything in the Image class. Since you already have a reference to a Bitmap, try using it instead. Do you know how to instantiate System ddls? class=System.Drawing.Image Well technically you do not instantiate an abstract class. That said, creating a reference to System.Drawing.Image works fine for me. -Leigh ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338850 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
But in general, if you have a non-abstract class in System.*, you should be able to instantiate it without specifying an assembly path as it'll be in the Global Assembly Cache. Dave, Do you know any common reasons why you might have to specify an assembly in this case? Because I can see System.Drawing in the GAC. But was unable to reference any of the classes unless I supplied a path. So I was curious as to what might cause that. -Leigh ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338851 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Anonymous Feedback Form: Prevent Malicious Code On Documents
Thanks for the confirmation Bryan, I figure it would be something pretty expensive. I was just curious if there was an open source deal out there. This feedback isn't used THAT much which is probably why we never noticed it being totally open. Matt.. I know that computer forensics folks have access to software that can scan images and essentially look for a certain amount of flesh tones in the images. I have no idea if there is a stripped down utility that could do this (as the software they play with is quite expensive)just letting you know there are more automated methods than humans viewing every image and allowing/dis-allowing ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338852 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Oracle 11g Upgrade Unable to select from CLOB datatype
CF8 doesn't support Oracle 11G, so you may be out of luck getting any official resolution. -- WSS4CF - WS-Security framework for CF http://wss4cf.riaforge.org/ On 5 November 2010 21:24, Wimbley, Noveta noveta.wimb...@sjcd.edu wrote: CF8 -Original Message- From: James Holmes [mailto:james.hol...@gmail.com] Sent: Friday, November 05, 2010 7:31 AM To: cf-talk Subject: Re: Oracle 11g Upgrade Unable to select from CLOB datatype Which version of CF are you using? -- WSS4CF - WS-Security framework for CF http://wss4cf.riaforge.org/ On 5 November 2010 15:50, Noveta Wimbley noveta.wimb...@sjcd.edu wrote: We have just upgraded from Oracle 10g to 11g. Now we have an application that will not select from clob datatype column. We are getting the following error: Error Executing Database Query. [Macromedia][Oracle JDBC Driver]No more data available to read. The error occurred in E:\Collab\iweb\webapps\admin\Test\drivertest.cfm: line 1 1 : cfquery name=getTXT datasource=prod 2 : select 3 : ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338853 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
Do you know any common reasons why you might have to specify an assembly in this case? Because I can see System.Drawing in the GAC. But was unable to reference any of the classes unless I supplied a path. So I was curious as to what might cause that. Not really. Are you able to reference other System classes without a path? System.Diagnostics is a good test class for this. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338854 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
DirectoryWatcher Event Gateway
I'm using the directory watcher event gateway to sync files between 2 servers that are load balanced. The client uses both file upload tools and local shares to update files (all located in an images directory). They have 2 sites and the images directory on one site is pushing 2GB and the other is about 1.2GB. So, I have 2 directory watcher instances running, one for each image directory. This is the same directory watcher, I just load 2 different config files. When images are added to server 1, they are copied to server 2, same for changes and deletes. My question is the following: I've never used directory watchers before. I have these scheduled to run at 5 minute incremenets and when they run the processor usage increases to over 30%. It makes me nervous consistently using this much proc so I want to know if this is normal. Is there a more efficient way to sync images between servers using coldfusion? FYI, the images are not all in the images directory, there are about 20 sub-directories and the directory watchers run recursively. The server this is running on is quite powerful. It's a 64bit windows server 2003 with a quad-core proc and 8GB RAM. The JVM has been tuned for this machine. This is CF8 Standard. (Both machines are the same) Thanks for any input. -Jake ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338855 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: DirectoryWatcher Event Gateway
You should try to setup dfs replication between the two servers / directory structures instead of using watch folders. That would be more efficient and would also give you near real time sync between the two servers. set and forget Mvh Helge Hetland WebSite AS Den 5. nov. 2010 kl. 16:50 skrev Jake Churchill reyna...@gmail.com: I'm using the directory watcher event gateway to sync files between 2 servers that are load balanced. The client uses both file upload tools and local shares to update files (all located in an images directory). They have 2 sites and the images directory on one site is pushing 2GB and the other is about 1.2GB. So, I have 2 directory watcher instances running, one for each image directory. This is the same directory watcher, I just load 2 different config files. When images are added to server 1, they are copied to server 2, same for changes and deletes. My question is the following: I've never used directory watchers before. I have these scheduled to run at 5 minute incremenets and when they run the processor usage increases to over 30%. It makes me nervous consistently using this much proc so I want to know if this is normal. Is there a more efficient way to sync images between servers using coldfusion? FYI, the images are not all in the images directory, there are about 20 sub-directories and the directory watchers run recursively. The server this is running on is quite powerful. It's a 64bit windows server 2003 with a quad-core proc and 8GB RAM. The JVM has been tuned for this machine. This is CF8 Standard. (Both machines are the same) Thanks for any input. -Jake ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338856 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
No. I needed to supply a path for System.Diagnostics too. But my test machine has multiple versions installed. So maybe that has something to do with it. -Leigh ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338857 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
No. I needed to supply a path for System.Diagnostics too. But my test machine has multiple versions installed. So maybe that has something to do with it. That's almost certainly the problem - you're in the newest version of DLL Hell. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338858 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Back to .NET integration - Enumeration issue
the newest version of DLL Hell. Darn, and here I thought we had graduated to purgatory .. -Leigh ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338859 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
I think I'm just making this way too hard...
I just want to run a query that compares a column value from today to the column value of yesterday on a MySQL 5 database table. I run: select totalNew from 04a_dailyNumberNewHMLSProperties where '#dateFormat(datetime, 'mmm d, ')#' = '#dateFormat(createODBCDateTime(dateDiff('d', '-1', now())), 'mmm d, ')#' and I get this error: Variable DATETIME is undefined. The table 04a_dailyNumberNewHMLSProperties has the following columns: countID (integer, auto-increment) totalNew (integer) datetime (timestamp, default CURRENT_TIMESTAMP, e.g. 2010-11-05 15:04:20) What am I doing wrong? (Besides mostly likely making this way harder than it should be... just fog on the brain today) Rick ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338860 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
On 11/5/2010 12:14 PM, Rick Faircloth wrote: What am I doing wrong? (Besides mostly likely making this way harder than it should be... just fog on the brain today) Rick I suspect that datatime is a column name in your database scheme. IF so that would mean you are trying to use a ColdFusion function to parse the value of a database column in the record set from a sql query inside the cfquery... block used to send the SQL statement to the database to ask for a recrord set. Or, maybe, more simply -- you have put the cart before the horse. You need to be using a database function around the database column, which for date functions varies from DBMS to DBMS. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338861 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
That's exactly right. On Fri, Nov 5, 2010 at 3:25 PM, Ian Skinner h...@ilsweb.com wrote: On 11/5/2010 12:14 PM, Rick Faircloth wrote: What am I doing wrong? (Besides mostly likely making this way harder than it should be... just fog on the brain today) Rick I suspect that datatime is a column name in your database scheme. IF so that would mean you are trying to use a ColdFusion function to parse the value of a database column in the record set from a sql query inside the cfquery... block used to send the SQL statement to the database to ask for a recrord set. Or, maybe, more simply -- you have put the cart before the horse. You need to be using a database function around the database column, which for date functions varies from DBMS to DBMS. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338862 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
On 11/5/2010 12:14 PM, Rick Faircloth wrote: What am I doing wrong? (Besides mostly likely making this way harder than it should be... just fog on the brain today) Rick On 11/5/2010 12:25 PM, Ian Skinner wrote: You need to be using a database function around the database column, which for date functions varies from DBMS to DBMS. P.S. And while there would be nothing wrong with continuing to use a ColdFusion function to create the date time value to be compared to the results of the database function us choose to use around the database column. It might just be simpler to use database function through out, as all DBMS have perfectly fine functions to get the current time from the system. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338863 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
plus 1 ;-) DB functions for DB columns...CF functions for values! On Fri, 2010-11-05 at 12:25 -0700, Ian Skinner wrote: On 11/5/2010 12:14 PM, Rick Faircloth wrote: What am I doing wrong? (Besides mostly likely making this way harder than it should be... just fog on the brain today) Rick I suspect that datatime is a column name in your database scheme. IF so that would mean you are trying to use a ColdFusion function to parse the value of a database column in the record set from a sql query inside the cfquery... block used to send the SQL statement to the database to ask for a recrord set. Or, maybe, more simply -- you have put the cart before the horse. You need to be using a database function around the database column, which for date functions varies from DBMS to DBMS. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338864 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Well, I switched the DB and CF functions around in the statement, changed the CF function in the first half of the comparison to a DB (MySQL 5) function, and changed the column name throwing the error to dateOfTotal to be certain using datetime as a column name was not the problem. But I still get an error, and I can't figure out why. I even renamed the table, in case using a number at the start of the table name was problematic. select totalNew from a_dailyNumberNewHMLSProperties where date_add(now(), -1 days) = '#dateAdd('d', -1, dateOfTotal)#' Variable dateOfTotal is undefined. How can that column name be undefined? Why is it not being understood in the SQL? A! ??? -Original Message- From: Ian Skinner [mailto:h...@ilsweb.com] Sent: Friday, November 05, 2010 3:49 PM To: cf-talk Subject: Re: I think I'm just making this way too hard... On 11/5/2010 12:14 PM, Rick Faircloth wrote: What am I doing wrong? (Besides mostly likely making this way harder than it should be... just fog on the brain today) Rick On 11/5/2010 12:25 PM, Ian Skinner wrote: You need to be using a database function around the database column, which for date functions varies from DBMS to DBMS. P.S. And while there would be nothing wrong with continuing to use a ColdFusion function to create the date time value to be compared to the results of the database function us choose to use around the database column. It might just be simpler to use database function through out, as all DBMS have perfectly fine functions to get the current time from the system. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338865 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Remove the # signs. You are telling cf to pass dateOfTotal to the server as a variable value. -Original Message- From: Rick Faircloth [mailto:r...@whitestonemedia.com] Sent: Friday, November 05, 2010 4:21 PM To: cf-talk Subject: RE: I think I'm just making this way too hard... Well, I switched the DB and CF functions around in the statement, changed the CF function in the first half of the comparison to a DB (MySQL 5) function, and changed the column name throwing the error to dateOfTotal to be certain using datetime as a column name was not the problem. But I still get an error, and I can't figure out why. I even renamed the table, in case using a number at the start of the table name was problematic. select totalNew from a_dailyNumberNewHMLSProperties where date_add(now(), -1 days) = '#dateAdd('d', -1, dateOfTotal)#' Variable dateOfTotal is undefined. How can that column name be undefined? Why is it not being understood in the SQL? A! ??? -Original Message- From: Ian Skinner [mailto:h...@ilsweb.com] Sent: Friday, November 05, 2010 3:49 PM To: cf-talk Subject: Re: I think I'm just making this way too hard... On 11/5/2010 12:14 PM, Rick Faircloth wrote: What am I doing wrong? (Besides mostly likely making this way harder than it should be... just fog on the brain today) Rick On 11/5/2010 12:25 PM, Ian Skinner wrote: You need to be using a database function around the database column, which for date functions varies from DBMS to DBMS. P.S. And while there would be nothing wrong with continuing to use a ColdFusion function to create the date time value to be compared to the results of the database function us choose to use around the database column. It might just be simpler to use database function through out, as all DBMS have perfectly fine functions to get the current time from the system. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338866 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
On 11/5/2010 1:20 PM, Rick Faircloth wrote: Variable dateOfTotal is undefined. How can that column name be undefined? Why is it not being understood in the SQL? Because ColdFusion is NOT your database server, it has NO IDEA what column exist or do not exist. It does not see 'dateOfTotal' as a database column. It sees it as a COLDFUSION variable. And it is telling you there is no such variable in your CFML code. All cfquery... does is bundle up a big string and send it to the database. It is the database the is able to parse the string into SQL commands and references to the Database schema, such as Column Names. To do what you want to do you need to include some strings that will represent DATABASE functions inside your cfquery... block, then when the string gets to the database server it will recognize them and give you the results you so desperately desire. Now I can't easily show you how this would work because database date and time functions vary considerably between one Database Management System and another. And you haven't told us what DBMS you are using. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338867 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
On 11/5/2010 12:14 PM, Rick Faircloth wrote: select totalNew from 04a_dailyNumberNewHMLSProperties where '#dateFormat(datetime, 'mmm d, ')#' = '#dateFormat(createODBCDateTime(dateDiff('d', '-1', now())), 'mmm d, ')#' But here is an example of how I would do it on one my Oracle Databases. SELETCT totalNoe FROM 04a_dailyNumberNewHMLSPropertise WHERE to_char(dateTime,'MON D, ') = to_char(CURRENT_DATE, 'MON D, ') Note: No ColdFusion at all and Oracle has some of the strangest date time functions around. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338868 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Rick you aren't even referencing a DB column anymore??? where date_add(now(), -1 days) = '#dateAdd('d', -1, dateOfTotal)#' You are comparing the current date -1 day (date_add(now(), -1 days)) to some date you have -1 day ('#dateAdd('d', -1, dateOfTotal)#') There is no point to using date_add() as you are not performing that function against a column in the DB (like your original issue stated). As far as dateOfTotal not being defined.would have to see the code where you set it to know why it's not being seen as defined. Perhaps sticking with your original query and using the date_add() function for the column. Cheers Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338869 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Apologies RickI now see that dateOfTotal is the new column name. You have it backwardsyou are using the DB function (date_add()) on now() and should be using dateAdd() (CF function)likewise...where you are using dateAdd() you should be using date_add(). Cheers Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338870 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: CF (8.0.0) performance vs PHP (5)
I think the cfexecute tag is definitely not the faster cf tag ever. As an ex php programmer and a current ColdFusion programmer I do have to say that there is usually a speed benefit to php over ColdFusion however, I do have to say that I think the overall benefits to ColdFusion far outweigh the cons to ColdFusion over php. I personally have had very, very few server or speed issues on my ecommerce site, which receives over a million page views a month. Check out my article about php vs ColdFusion. http://paulalkema.com/post.cfm/php-vs-coldfusion Paul Alkema ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338871 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Thanks, everyone, for the feedback. I *finally* got this stupid (that's the headache talking) query working. Seems like working with comparing dates in queries has always been a chore. Mostly because I do it rarely. And, everyone was right, I did have MySQL working on the part that CF should have been processing. I did mention in an earlier post that it was MySQL 5. Anyway, here's what finally worked: select totalNew from 04a_dailyNumberNewHMLSProperties where day(date_add(dateOfTotal, interval -1 day)) = #dateFormat(dateAdd('d', -1, now()), 'd')# Now I can rest in peace. (or pieces if my headache does finally split my head) Have a good evening everyone! Rick -Original Message- From: Bryan Stevenson [mailto:br...@electricedgesystems.com] Sent: Friday, November 05, 2010 4:50 PM To: cf-talk Subject: RE: I think I'm just making this way too hard... Apologies RickI now see that dateOfTotal is the new column name. You have it backwardsyou are using the DB function (date_add()) on now() and should be using dateAdd() (CF function)likewise...where you are using dateAdd() you should be using date_add(). Cheers Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338872 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Getting rid of maliceous code embedded in a jpg
I am trying to allow perspective clients to try my templates image tools in order to see if it will help sway them. I do not have any image samples with malicious code nor do I want any. My question is if I use the coldfusion image tags or my trusty cf_imagecr after the upload will it remove any of this or how about I save it as a png? Terry ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338873 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
On 11/5/2010 2:44 PM, Rick Faircloth wrote: Anyway, here's what finally worked: select totalNew from 04a_dailyNumberNewHMLSProperties where day(date_add(dateOfTotal, interval -1 day)) = #dateFormat(dateAdd('d', -1, now()), 'd')# I'm glad you got something to work! But you may want to reconsider your choice of function. A quick internet search showed that the MySQL 5 day() function is to: Returns the day of the month for /|date|/, in the range |1| to |31| Thus day('2010-11-05') will return 5 as will the associated dateFormat() function. But since you do not include month or year portion you are going to return results of every dateOfTotal record that is the 5th day of the month for every month for every year in your database. I imagine that is not the desired result. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338874 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Something is still not right... Given this data set: Record 1: CountID 1, totalNew 927, dateOfTotal 2010-11-04 14:14:02 Record 2: CountID 2, totalNew 901, dateOfTotal 2010-11-05 15:04:20 And these queries: cfquery name = getYesterdayNewHMLSProperties datasource=myDatasource select totalNew from 04a_dailyNumberNewHMLSProperties where day(date_add(dateOfTotal, interval -1 day)) = #dateFormat(dateAdd('d', -1, now()), 'd')# /cfquery cfquery name = getTodayNewHMLSProperties datasource=myDatasource select totalNew from 04a_dailyNumberNewHMLSProperties where day(dateOfTotal) = #dateFormat(now(), 'd')# /cfquery I'm getting totalNew in both queries as 901. Seems to me that the first query Yesterday should return 927. Seems to me that the second query Today should return 901. But when I output getYesterdayNewHMLSProperties.totalNew, I get 901, instead of 927. And when I output getTodayNewHMLSProperties.totalNew, I get 901, which is correct. I've verified that day(dateOfTotal) returns 5 and #dateFormat(now(), 'd')# returns 5. Also, day(date_add(dateOfTotal, inverval -1 day)) returns 4 and #dateFormat(dateAdd('d', -1, now()), 'd')# returns 4. So the queries are operating on the correct day of the month. The variables aren't overwriting each other somehow, are they? This is just one of those days where I wonder If I have any future in this business. Rick -Original Message- From: Rick Faircloth [mailto:r...@whitestonemedia.com] Sent: Friday, November 05, 2010 5:45 PM To: cf-talk Subject: RE: I think I'm just making this way too hard... Thanks, everyone, for the feedback. I *finally* got this stupid (that's the headache talking) query working. Seems like working with comparing dates in queries has always been a chore. Mostly because I do it rarely. And, everyone was right, I did have MySQL working on the part that CF should have been processing. I did mention in an earlier post that it was MySQL 5. Anyway, here's what finally worked: select totalNew from 04a_dailyNumberNewHMLSProperties where day(date_add(dateOfTotal, interval -1 day)) = #dateFormat(dateAdd('d', -1, now()), 'd')# Now I can rest in peace. (or pieces if my headache does finally split my head) Have a good evening everyone! Rick -Original Message- From: Bryan Stevenson [mailto:br...@electricedgesystems.com] Sent: Friday, November 05, 2010 4:50 PM To: cf-talk Subject: RE: I think I'm just making this way too hard... Apologies RickI now see that dateOfTotal is the new column name. You have it backwardsyou are using the DB function (date_add()) on now() and should be using dateAdd() (CF function)likewise...where you are using dateAdd() you should be using date_add(). Cheers Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338875 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Certainly true, Ian. Once I get the day part working correctly, I'll add the month and year to it, as well. I thought I'd go for the most simple approach first, then make it more complicated. It's still not returning proper values in the different queries, however. But at least I'm not getting CF or MySQL errors! (see the post I just sent for the problem...) Rick -Original Message- From: Ian Skinner [mailto:h...@ilsweb.com] Sent: Friday, November 05, 2010 5:57 PM To: cf-talk Subject: Re: I think I'm just making this way too hard... On 11/5/2010 2:44 PM, Rick Faircloth wrote: Anyway, here's what finally worked: select totalNew from 04a_dailyNumberNewHMLSProperties where day(date_add(dateOfTotal, interval -1 day)) = #dateFormat(dateAdd('d', -1, now()), 'd')# I'm glad you got something to work! But you may want to reconsider your choice of function. A quick internet search showed that the MySQL 5 day() function is to: Returns the day of the month for /|date|/, in the range |1| to |31| Thus day('2010-11-05') will return 5 as will the associated dateFormat() function. But since you do not include month or year portion you are going to return results of every dateOfTotal record that is the 5th day of the month for every month for every year in your database. I imagine that is not the desired result. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338876 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
cfheader/cfheader not working as expected
I want to do simple download of a web page to Excel. I am using CF7, browser is IE6SP2 and Excel 2007. The single standalone file is test.cfm. Here is the code: cfheader name=Content-Disposition value=inline;filename=download.xls / cfcontent type=application/vnd.ms-excel / table tr tdHello 1/td tdColumn 2/td tdColumn 3/td /tr /table Excel open as expected but the filename in Excel is test.cfm rather than download.xls and is opened in [Read-Only] mode. Any ideas? ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338877 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Without knowing what the other records in the table may be like I'd have to say there are many records that would contain a date with a day of 4 or 5. IN other words, 4 doesn't just match yesterday, it also matches the 4th day of any month. So if you have older records, that could be skewing the results. Other than that your logic seems soundsbut we don't really have the whole picture... I can say TGIF!! You can take a breather soon Rick!! ;-) Cheers Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338878 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
On 11/5/2010 3:31 PM, Rick Faircloth wrote: Something is still not right... I would suggest you stop looking at date-time values as a collection of sub values, such as Days or Minutes. You need to consider it as a single value that you want to compare to another value. Trying me best to understand the MySQL documentation, it looks like it would be as simple as. WHERE date(date_add(dateOFTotal, interval -1 day))) = date_add(curdate(), interval 01 day) ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338879 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
On 11/5/2010 3:52 PM, Ian Skinner wrote: WHERE date(date_add(dateOFTotal, interval -1 day))) = date_add(curdate(), interval 01 day) And if I could type and|or proof read: WHERE date(date_add(dateOFTotal, interval -1 day))) = date_add(curdate(), interval -1 day) ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338880 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: I think I'm just making this way too hard...
Rick, I think you might be able to simplify this further, and take ColdFusion out of the query altogether. Bear in mind I've never used MySQL, but according to the MySQL docs something like this should work: select totalNew from 04a_dailyNumberNewHMLSProperties where datediff(curdate(),dateOfTotal) = 1 The DateDiff(expr1,expr2) function returns expr1 â expr2 expressed as a value in days from one date to the other. expr1 and expr2 are date or date-and-time expressions. Only the date parts of the values are used in the calculation. HTH, Carl Something is still not right... Given this data set: Record 1: CountID 1, totalNew 927, dateOfTotal 2010-11-04 14:14:02 Record 2: CountID 2, totalNew 901, dateOfTotal 2010-11-05 15:04:20 And these queries: cfquery name = getYesterdayNewHMLSProperties datasource=myDatasource select totalNew from 04a_dailyNumberNewHMLSProperties where day(date_add(dateOfTotal, interval -1 day)) = #dateFormat(dateAdd('d', -1, now()), 'd')# /cfquery cfquery name = getTodayNewHMLSProperties datasource=myDatasource select totalNew from 04a_dailyNumberNewHMLSProperties where day(dateOfTotal) = #dateFormat(now(), 'd')# /cfquery I'm getting totalNew in both queries as 901. Seems to me that the first query Yesterday should return 927. Seems to me that the second query Today should return 901. But when I output getYesterdayNewHMLSProperties.totalNew, I get 901, instead of 927. And when I output getTodayNewHMLSProperties.totalNew, I get 901, which is correct. I've verified that day(dateOfTotal) returns 5 and #dateFormat(now(), 'd')# returns 5. Also, day(date_add(dateOfTotal, inverval -1 day)) returns 4 and #dateFormat(dateAdd('d', -1, now()), 'd')# returns 4. So the queries are operating on the correct day of the month. The variables aren't overwriting each other somehow, are they? This is just one of those days where I wonder If I have any future in this business. Rick Thanks, everyone, for the feedback. I *finally* got this stupid (that's the headache talking) query working. Seems like working with comparing dates in queries has always been a chore. Mostly because I do it rarely. And, everyone was right, I did have MySQL working on the part that CF should have been processing. I did mention in an earlier post that it was MySQL 5. Anyway, here's what finally worked: select totalNew from 04a_dailyNumberNewHMLSProperties where day(date_add(dateOfTotal, interval -1 day)) = #dateFormat(dateAdd('d', -1, now()), 'd')# Now I can rest in peace. (or pieces if my headache does finally split my head) Have a good evening everyone! Rick Apologies RickI now see that dateOfTotal is the new column name. You have it backwardsyou are using the DB function (date_add()) on now() and should be using dateAdd() (CF function)likewise...where you are using dateAdd() you should be using date_add(). Cheers Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338881 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: cfheader/cfheader not working as expected
cfheader name=Content-Disposition value=*inline*;filename=download.xls / Change inline to attachment so that the browser knows this is a separate, attached file to view OR download AND NOT an inline part of the currently viewed file: test.cfm. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338882 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Good idea, but those are the only two records in the table! I'm just working up the proof-of-concept at this point, preparing to implement the full functionality. Just can't understand why both queries return the same value... -Original Message- From: Bryan Stevenson [mailto:br...@electricedgesystems.com] Sent: Friday, November 05, 2010 6:49 PM To: cf-talk Subject: RE: I think I'm just making this way too hard... Without knowing what the other records in the table may be like I'd have to say there are many records that would contain a date with a day of 4 or 5. IN other words, 4 doesn't just match yesterday, it also matches the 4th day of any month. So if you have older records, that could be skewing the results. Other than that your logic seems soundsbut we don't really have the whole picture... I can say TGIF!! You can take a breather soon Rick!! ;-) Cheers ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338883 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
So much for that plan ;-) Have you tried each query with hardcoded values (i.e. stuff in the 4s and 5s where you think they should be)? If that works, then what you think you are running (when using dates and date functions) may not really be running what you think. Other than that...I'm outta ideas (and here for the day). Good luck!! Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338884 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Thanks, Carl Ian for the latest suggestion on using the simplied dateDiff curdate. That seems to work fine. Running: select totalNew from04a_dailyNumberNewHMLSProperties where dateDiff(curdate(),dateOfTotal) = 1 does return the correct number for yesterday, 927. And running: select totalNew from04a_dailyNumberNewHMLSProperties where dateDiff(curdate(),dateOfTotal) = 0 returns the correct number for today, 901. How simple and elegant! I can feel my headache being soothed already. Time to quit for the day! Thanks, again! Rick -Original Message- From: Carl Von Stetten [mailto:cmvon...@hotmail.com] Sent: Friday, November 05, 2010 6:52 PM To: cf-talk Subject: Re: I think I'm just making this way too hard... Rick, I think you might be able to simplify this further, and take ColdFusion out of the query altogether. Bear in mind I've never used MySQL, but according to the MySQL docs something like this should work: select totalNew from 04a_dailyNumberNewHMLSProperties where datediff(curdate(),dateOfTotal) = 1 The DateDiff(expr1,expr2) function returns expr1 ââ¬â expr2 expressed as a value in days from one date to the other. expr1 and expr2 are date or date-and-time expressions. Only the date parts of the values are used in the calculation. HTH, Carl ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338885 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: I think I'm just making this way too hard...
Thanks for the suggestion. I did use hard-coded dates, but not 4's and 5's. Next step would have been that. However, per my latest post before this, I think we have a winner! :o) -Original Message- From: Bryan Stevenson [mailto:br...@electricedgesystems.com] Sent: Friday, November 05, 2010 7:15 PM To: cf-talk Subject: RE: I think I'm just making this way too hard... So much for that plan ;-) Have you tried each query with hardcoded values (i.e. stuff in the 4s and 5s where you think they should be)? If that works, then what you think you are running (when using dates and date functions) may not really be running what you think. Other than that...I'm outta ideas (and here for the day). Good luck!! Bryan Stevenson B.Comm. VP Director of E-Commerce Development Electric Edge Systems Group Inc. phone: 250.480.0642 fax: 250.480.1264 cell: 250.920.8830 e-mail: br...@electricedgesystems.com web: www.electricedgesystems.com Notice: This message, including any attachments, is confidential and may contain information that is privileged or exempt from disclosure. It is intended only for the person to whom it is addressed unless expressly authorized otherwise by the sender. If you are not an authorized recipient, please notify the sender immediately and permanently destroy all copies of this message and attachments. Please consider the environment before printing this e-mail ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338886 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Closing Browser expires session/cookie
So I have an app that uses cflogin, which works great if the user logs in and out from the same browser. Now here is where I am stumped: -User logs in, then closes the browser -System does not allow the same user to be logged in more than once -System logs all logged in users -System removes user from log onSessionEnd() How can I remove the user from the log when they close the browser? Here is my logic: onSessionStart{ cfif not isDefined(cookie.CFID) cfcookie name=CFID value=#SESSION.CFID# expires=NOW/ cfcookie name=CFTOKEN value=#SESSION.CFTOKEN# expires=NOW/ /cfif } onSessionEnd{ delogUser(arguments.SessionScope.userid) } login{ cfloginuser name=#uname# password=#pword# logUser(uname,pword) } logout{ cflogout delogUser(session.userid) } onRequest{ if(isDefined(cookie.cfid) and session.loggedin eq false){ //this is in case the user closes the browser and then opens it again checkCookieAgainstLogAndDelogUser(cookie.cfid) } } So yeah, the user closes the browser but that doesn't fire the logout method or clear the cookie or session. When the user tries to login with another browser without actually hitting logout, they cant log in. The only way is to use the same browser that they originally closed. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338887 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Closing Browser expires session/cookie
On 11/5/2010 4:26 PM, Tony Bentley wrote: How can I remove the user from the log when they close the browser? You really can't! Browsers don't go back to all the web servers that the user visted and tell them I'm being closed now. So yeah, the user closes the browser but that doesn't fire the logout method or clear the cookie or session. When the user tries to login with another browser without actually hitting logout, they cant log in. The only way is to use the same browser that they originally closed. And it is not going to. The better way is probably to not prevent the logging in of user, but close the login state of the previous session. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:33 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Closing Browser expires session/cookie
Arn't they logged out automatically when the session expires ? -Original Message- From: Tony Bentley [mailto:cascadefreehee...@gmail.com] Sent: 05 November 2010 23:27 To: cf-talk Subject: Closing Browser expires session/cookie So I have an app that uses cflogin, which works great if the user logs in and out from the same browser. Now here is where I am stumped: -User logs in, then closes the browser -System does not allow the same user to be logged in more than once -System logs all logged in users -System removes user from log onSessionEnd() How can I remove the user from the log when they close the browser? Here is my logic: onSessionStart{ cfif not isDefined(cookie.CFID) cfcookie name=CFID value=#SESSION.CFID# expires=NOW/ cfcookie name=CFTOKEN value=#SESSION.CFTOKEN# expires=NOW/ /cfif } onSessionEnd{ delogUser(arguments.SessionScope.userid) } login{ cfloginuser name=#uname# password=#pword# logUser(uname,pword) } logout{ cflogout delogUser(session.userid) } onRequest{ if(isDefined(cookie.cfid) and session.loggedin eq false){ //this is in case the user closes the browser and then opens it again checkCookieAgainstLogAndDelogUser(cookie.cfid) } } So yeah, the user closes the browser but that doesn't fire the logout method or clear the cookie or session. When the user tries to login with another browser without actually hitting logout, they cant log in. The only way is to use the same browser that they originally closed. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338889 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Closing Browser expires session/cookie
Yeah but their session expires a couple of hours after they close the browser. So I could expire the session at a shorter timespan but if I can do it when the browser closes, that would be better. On Fri, Nov 5, 2010 at 4:50 PM, Russ Michaels r...@michaels.me.uk wrote: Arn't they logged out automatically when the session expires ? ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338890 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Closing Browser expires session/cookie
Well you can use javascript to detect when the browser is closed and then call another cfm page or make an ajax call to end the session. e.g. body onunload=closesession() -- Russ Michaels http://www.bluethunderinternet.com: B2B hosting, VPS's, Exchange, CF, Railo www.cfmldeveloper.com : CFML community, FREE ColdFusion/Railo hosting http://www.michaels.me.uk : My Blog skype me : russmichaels -Original Message- From: Tony Bentley [mailto:cascadefreehee...@gmail.com] Sent: 05 November 2010 23:54 To: cf-talk Subject: Re: Closing Browser expires session/cookie Yeah but their session expires a couple of hours after they close the browser. So I could expire the session at a shorter timespan but if I can do it when the browser closes, that would be better. On Fri, Nov 5, 2010 at 4:50 PM, Russ Michaels r...@michaels.me.uk wrote: Arn't they logged out automatically when the session expires ? ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338891 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Closing Browser expires session/cookie
Um, won't that run every time you move to a new page in the same app? On Fri, Nov 5, 2010 at 5:49 PM, Russ Michaels r...@michaels.me.uk wrote: Well you can use javascript to detect when the browser is closed and then call another cfm page or make an ajax call to end the session. e.g. body onunload=closesession() ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338892 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Closing Browser expires session/cookie
Pass, you would have to test that, it was just a suggestion :-) -Original Message- From: Sean Corfield [mailto:seancorfi...@gmail.com] Sent: 06 November 2010 01:26 To: cf-talk Subject: Re: Closing Browser expires session/cookie Um, won't that run every time you move to a new page in the same app? On Fri, Nov 5, 2010 at 5:49 PM, Russ Michaels r...@michaels.me.uk wrote: Well you can use javascript to detect when the browser is closed and then call another cfm page or make an ajax call to end the session. e.g. body onunload=closesession() ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338893 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Getting rid of maliceous code embedded in a jpg
I am trying to allow perspective clients to try my templates image tools in order to see if it will help sway them. I do not have any image samples with malicious code nor do I want any. My question is if I use the coldfusion image tags or my trusty cf_imagecr after the upload will it remove any of this or how about I save it as a png? I do not want to open up any possible security issues. Terry ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338894 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Closing Browser expires session/cookie
I have done this before. Let me look through my code and get back to you. On Fri, Nov 5, 2010 at 7:26 PM, Tony Bentley cascadefreehee...@gmail.comwrote: So I have an app that uses cflogin, which works great if the user logs in and out from the same browser. Now here is where I am stumped: -User logs in, then closes the browser -System does not allow the same user to be logged in more than once -System logs all logged in users -System removes user from log onSessionEnd() How can I remove the user from the log when they close the browser? Here is my logic: onSessionStart{ cfif not isDefined(cookie.CFID) cfcookie name=CFID value=#SESSION.CFID# expires=NOW/ cfcookie name=CFTOKEN value=#SESSION.CFTOKEN# expires=NOW/ /cfif } onSessionEnd{ delogUser(arguments.SessionScope.userid) } login{ cfloginuser name=#uname# password=#pword# logUser(uname,pword) } logout{ cflogout delogUser(session.userid) } onRequest{ if(isDefined(cookie.cfid) and session.loggedin eq false){ //this is in case the user closes the browser and then opens it again checkCookieAgainstLogAndDelogUser(cookie.cfid) } } So yeah, the user closes the browser but that doesn't fire the logout method or clear the cookie or session. When the user tries to login with another browser without actually hitting logout, they cant log in. The only way is to use the same browser that they originally closed. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338895 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
jquery
why would my jquery validation code styles not show up? I recently changed my style sheet on an app...before I made changes the jquery styling showed up (yellow background...red text). Now I get the This field is required message but with no style. Any suggestions? TIA ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338896 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Closing Browser expires session/cookie
On Fri, Nov 5, 2010 at 5:26 PM, Tony Bentley wrote: So I have an app that uses cflogin, which works great if the user logs in and out from the same browser. Now here is where I am stumped: -User logs in, then closes the browser -System does not allow the same user to be logged in more than once -System logs all logged in users -System removes user from log onSessionEnd() How can I remove the user from the log when they close the browser? I think the best you can do is invalidate their previous session when they try to log in again. So they can still only be logged in once, but it's the current session that is the master, and the old session is discarded/invalidated. Due to the nature of sessions, this is the best you can do. A thread on Ben's blog goes into a lot of depth about it. Probably the first hit on google: http://www.lmgtfy.com/?q=expiring+cookies+when+browser+closes+coldfusionl=1 (enable javascript to see the nifty typing action) :) :Den -- A word is not the same with one writer as with another. One tears it from his guts. The other pulls it out of his overcoat pocket. Charles Peguy ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338897 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: jquery
Maybe because you recently changed your style sheet? Can you view source and verify that the style you expect to be applied (which I assume is an external .css file) is being included with the correct path? On Fri, Nov 5, 2010 at 9:23 PM, Monique Boea moniqueb...@gmail.com wrote: why would my jquery validation code styles not show up? I recently changed my style sheet on an app...before I made changes the jquery styling showed up (yellow background...red text). Now I get the This field is required message but with no style. Any suggestions? TIA ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338898 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Getting rid of maliceous code embedded in a jpg
On Fri, Nov 5, 2010 at 8:27 PM, Terry Troxel wrote: I am trying to allow perspective clients to try my templates image tools in order to see if it will help sway them. I do not have any image samples with malicious code nor do I want any. My question is if I use the coldfusion image tags or my trusty cf_imagecr after the upload will it remove any of this or how about I save it as a png? I do not want to open up any possible security issues. There was an awesome thread on the Railo list, titled CFFile and MIME types, that covered this issue a bit. I think in the end, a virus scanner was the best bet? Maybe trying to convert the image to a different type would do the trick too, I can't remember if that was covered. There was a link for something that looked interesting: http://hul.harvard.edu/jhove/ But I don't know if it would work. I never got around to writing a wrapper for it to test with. =) I bet conversion would be enough, though you'd probably run into the odd legitimate file that didn't convert, for whatever reason. Better that than the alternative though, I say. There are potential false-positives with virus scanners too, although I'd wager less. :Den -- Any father whose son raises his hand against him is guilty of having produced a son who raised his hand against him. Charles Peguy ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338899 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Moving to DC
In my previous job, I commuted from Manassas, Virginia to L'Enfant Plaza in DC. Using a combination of driving to the Vienna Orange Line metro stop, and the DC metro, the commute would take about 2 hours one way. Commuting to L'Enfant Plaza from Manassas using the Virginia Rail Express took about an hour. That said, if you're still looking for a job in this area, don't just look at DC, Alexandria and Arlington. There aare quite a few CF related positions in Reston, Herndon and Fairfax county. The downside for most of those place sis that public transportation is very minimal - you'll most likely have to drive. hth, larry On Fri, Nov 5, 2010 at 9:40 AM, sonicDivx sonicd...@gmail.com wrote: Jason, I commuted from up in White Marsh , Md via MARC train for 3 years and know lots of people who do. Its not the best but as Scott says further out gives you a lot more options. just need to weigh pro cons. So in my case it was 15 min. to train station and then 1 -1.5 to DC so was getting up anywhere from 4-5ish depending on train. Plus no driving into DC, downside train delays and limited train times based on my stop (closer to dc better) So look at the MARC train lines to find places. Also Scott is right about salary. True Senior developers should not have trouble in DC getting $100k. Baltimore may be less, though has been improving . More CF jobs in DC than Baltimore. If you are still looking for job , make sure resume is on DICE. A large portion of the recruiters use that (I get anywhere from 1-3 direct requests a week). Good luck. Kevin On Fri, Nov 5, 2010 at 8:32 AM, Scott Stewart webmas...@sstwebworks.com wrote: Jason, Here's my take.. it's very dependant on the following: Your salary coming in, what your looking for house-wise, and what you consider a long commute. There are commuter options even in the way outer suburbs... I'm currently living about 13 miles past Leesburg (Loudoun County), and I take a commuter bus in. It's about two hours but... I don't have to drive. The DC Metro system is being extended out toward Dulles Airport into Sterling in Loudoun County.. There are rail options from Fredericksburg, Manassas, Baltimore, and as far west as Harper's Ferry West Virginia. The further out you are the lower housing prices are, for the most part. Most of the 'burbs are pretty safe... There's a fairly wide range salary wise, but I wouldn't accept less than $80k. I've seen positions offer salaries as high as 100K. Northern Virginia has an interesting tax situation, we are the cash cow for Virginia, however we get very little back in services, consequently the NoVa counties have to cover their own infrastructure costs, so property taxes across NoVa are fairly high. As an example, the Virginia Department of Transportation, handed Loudoun County a check for $1000 as VDOT's share of covering state road costs.. saying that it all they could afford -Original Message- From: Jason Birchman [mailto:birchma...@yahoo.com] Sent: Thursday, November 04, 2010 3:25 PM To: cf-jobs-talk Subject: Moving to DC I am a Senior ColdFusion Developer that is moving out to the Washington, DC. Obviously housing is a premium in the DC area. I would like to buy or rent a house in one of the suburbs, so that we can have a fenced in yard for my dogs. What suburbs are the safest and most affordable in DC that have single family homes (not townhomes/apartments)? Which area is lower in taxes? Commuting by train/light rail would be ideal. Also, what is a typical salary range for Senior CF Developers in the DC area? Thanks! - Jason ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-jobs-talk/message.cfm/messageid:4354 Subscription: http://www.houseoffusion.com/groups/cf-jobs-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-jobs-talk/unsubscribe.cfm
Re: Moving to DC
Simon: Perfect. That's exactly what I am looking for. I know very little about DC neighborhoods, so this really helps. I need a yard because I am bringing 3 dogs with me - and I prefer they not do their business in the house. :) And I have done the multi-unit living with 1 dog - which was a nightmare. I am looking to buy but not cool to the idea of renting, but this really gives me an idea of where to begin my search. JB From:Simon Horwith si...@horwith.com To:cf-jobs-talk cf-jobs-talk@houseoffusion.com Sent: Thu, November 4, 2010 10:20:36 PM Subject: Re: Moving to DC So if I understand: you want to commute into downtown via Metro, plan to buy (otherwise you wouldn't care about property taxes), and want a place with a yard and low crime. I'm not sure what you consider a good price, but my immediate gut is to say you should look at neighborhoods toward the VA end of the Orange line. Basically, from VA Square to Fairfax stations you should be able to find places that have a yard and aren't priced outrageously (which is relative, mind you). Greenbelt isn't a terrible suggestion, though I wouldn't live there, myself (of course, I lived downtown, so take what I say about the suburbs with a grain of salt). There are some OK neighborhoods towards the VA end of the blue line (near Franconia/Springfield) but I personally wouldn't bother with it unless you're really into traffic and malls (and a lot of other nonsense, including high odds of soul-less neighbors). Shady Grove, and suburbs beyond (Damascus, all the way out to Fredrick) is a really good option for you if you want to rent (prices, unless you go WAY out, aren't going to be low if you're looking for a yard, etc nd plan to buy) and don't mind driving just a little to get to the metro station. To be honest, that's about all I can recommend that's out in the suburbs. If I were looking for what you describe personally, I'd maybe look towards the end of the orange line or red line like I said, but would most likely look in town at neighborhoods that E-W are from 16th St NW to 10th St NE and N-S are from Florida Ave to Capital. If you aren't looking to spend too much really and you really want that yard, I'd say your best decent bet in town is going to be somewhere between the Easternmost 10 blocks of NW and the Western most 10 blocks of NE My $0.02. ~Simon Simon Horwith CTO, Nylon Technology http://www.nylontechnology.com blog - http://www.horwith.com On 11/4/2010 3:24 PM, Jason Birchman wrote: I am a Senior ColdFusion Developer that is moving out to the Washington, DC. Obviously housing is a premium in the DC area. I would like to buy or rent a house in one of the suburbs, so that we can have a fenced in yard for my dogs. What suburbs are the safest and most affordable in DC that have single family homes (not townhomes/apartments)? Which area is lower in taxes? Commuting by train/light rail would be ideal. Also, what is a typical salary range for Senior CF Developers in the DC area? Thanks! - Jason ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-jobs-talk/message.cfm/messageid:4355 Subscription: http://www.houseoffusion.com/groups/cf-jobs-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-jobs-talk/unsubscribe.cfm