RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-04 Thread Bobby Hartsfield

I wouldn't mind taking a look at what you put together for an event gateway
if the offer still stands.


-Original Message-
From: Raymond Camden [mailto:rcam...@gmail.com] 
Sent: Thursday, June 03, 2010 12:01 PM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


FYI, I've got some sample code to show how you can use a scheduled
task to do this, or an event gateway.


On Thu, Jun 3, 2010 at 10:48 AM, DURETTE, STEVEN J (ATTASIAIT)
sd1...@att.com wrote:

 Why don't you use a hybrid... ?Drop the files in a directory, then when
 it's that files turn, check to see if a file of the same name is in a
 subdirectory called watermarked (or something like that). If it is just
 serve up the watermarked file. ?If not have the process create the
 watermarked file and put it in the watermarked directory.

 This allows you the flexibility of dropping files in there without
 worrying about it and it will speed up the process because the older
 files will be static watermarked, and you still have the originals if
 you ever need un-watermarked files.

 Steve


 -Original Message-
 From: Bobby Hartsfield [mailto:bo...@acoderslife.com]
 Sent: Thursday, June 03, 2010 9:50 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 I gave up. Nothing that resolved the issue was a valid long term
 solution. I've watermarked the images manually and removed all of the
 code to handle it on the fly.

 I'll still use it in a tool that watermarks the images as I upload them
 I guess.

 So now it is very simple...

 cfdirectory name=variables.mastImages action=list
 directory=#expandPath('/images/mastimages/')# filter=*.jpg /

 cfset variables.mastImg = randRange(1,variables.mastImages.recordcount)
 /

 cfheader name=Content-Disposition value=inline;
 #variables.mastImages['name'][variables.mastImg]#

 cfcontent
 type=image/jpg reset=true file=#expandpath('/images/mastimages/'
  variables.mastImages['name'][variables.mastImg])# /

 Thanks for all the input.







 



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334299
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-04 Thread Raymond Camden

Code is written - just ran into some other stuff yesterday which
prevented me from blogging it. Will be the first thing I do once I get
to work today. :)

On Thu, Jun 3, 2010 at 5:02 PM, Bobby Hartsfield bo...@acoderslife.com wrote:

 I wouldn't mind taking a look at what you put together for an event gateway
 if the offer still stands.


 -Original Message-
 From: Raymond Camden [mailto:rcam...@gmail.com]
 Sent: Thursday, June 03, 2010 12:01 PM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 FYI, I've got some sample code to show how you can use a scheduled
 task to do this, or an event gateway.


 On Thu, Jun 3, 2010 at 10:48 AM, DURETTE, STEVEN J (ATTASIAIT)
 sd1...@att.com wrote:

 Why don't you use a hybrid... ?Drop the files in a directory, then when
 it's that files turn, check to see if a file of the same name is in a
 subdirectory called watermarked (or something like that). If it is just
 serve up the watermarked file. ?If not have the process create the
 watermarked file and put it in the watermarked directory.

 This allows you the flexibility of dropping files in there without
 worrying about it and it will speed up the process because the older
 files will be static watermarked, and you still have the originals if
 you ever need un-watermarked files.

 Steve


 -Original Message-
 From: Bobby Hartsfield [mailto:bo...@acoderslife.com]
 Sent: Thursday, June 03, 2010 9:50 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 I gave up. Nothing that resolved the issue was a valid long term
 solution. I've watermarked the images manually and removed all of the
 code to handle it on the fly.

 I'll still use it in a tool that watermarks the images as I upload them
 I guess.

 So now it is very simple...

 cfdirectory name=variables.mastImages action=list
 directory=#expandPath('/images/mastimages/')# filter=*.jpg /

 cfset variables.mastImg = randRange(1,variables.mastImages.recordcount)
 /

 cfheader name=Content-Disposition value=inline;
 #variables.mastImages['name'][variables.mastImg]#

 cfcontent
 type=image/jpg reset=true file=#expandpath('/images/mastimages/'
  variables.mastImages['name'][variables.mastImg])# /

 Thanks for all the input.











 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334301
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-04 Thread Raymond Camden

http://www.coldfusionjedi.com/index.cfm/2010/6/4/Automating-watermarking-of-images-with-ColdFusion


On Fri, Jun 4, 2010 at 6:40 AM, Raymond Camden rcam...@gmail.com wrote:
 Code is written - just ran into some other stuff yesterday which
 prevented me from blogging it. Will be the first thing I do once I get
 to work today. :)

 On Thu, Jun 3, 2010 at 5:02 PM, Bobby Hartsfield bo...@acoderslife.com 
 wrote:

 I wouldn't mind taking a look at what you put together for an event gateway
 if the offer still stands.


 -Original Message-
 From: Raymond Camden [mailto:rcam...@gmail.com]
 Sent: Thursday, June 03, 2010 12:01 PM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 FYI, I've got some sample code to show how you can use a scheduled
 task to do this, or an event gateway.


 On Thu, Jun 3, 2010 at 10:48 AM, DURETTE, STEVEN J (ATTASIAIT)
 sd1...@att.com wrote:

 Why don't you use a hybrid... ?Drop the files in a directory, then when
 it's that files turn, check to see if a file of the same name is in a
 subdirectory called watermarked (or something like that). If it is just
 serve up the watermarked file. ?If not have the process create the
 watermarked file and put it in the watermarked directory.

 This allows you the flexibility of dropping files in there without
 worrying about it and it will speed up the process because the older
 files will be static watermarked, and you still have the originals if
 you ever need un-watermarked files.

 Steve


 -Original Message-
 From: Bobby Hartsfield [mailto:bo...@acoderslife.com]
 Sent: Thursday, June 03, 2010 9:50 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 I gave up. Nothing that resolved the issue was a valid long term
 solution. I've watermarked the images manually and removed all of the
 code to handle it on the fly.

 I'll still use it in a tool that watermarks the images as I upload them
 I guess.

 So now it is very simple...

 cfdirectory name=variables.mastImages action=list
 directory=#expandPath('/images/mastimages/')# filter=*.jpg /

 cfset variables.mastImg = randRange(1,variables.mastImages.recordcount)
 /

 cfheader name=Content-Disposition value=inline;
 #variables.mastImages['name'][variables.mastImg]#

 cfcontent
 type=image/jpg reset=true file=#expandpath('/images/mastimages/'
  variables.mastImages['name'][variables.mastImg])# /

 Thanks for all the input.











 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334302
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-04 Thread Bobby Hartsfield

Within 30 seconds they were all noticed by the event gateway,
watermarked, and copied over. Like magic. :)

See how cool magic is? Heh

Thanks Ray; good stuff. I'll definitely be playing around with this (and
trying to talk the guys hosting my site into letting me set it up on the
server)

I've got the first part done already. Last night I wrote a template that
loops over a directory called /process/. If it finds any images in there it
will loop over them and:

1) load the image into an image object
2) write it to /unwatermarked/ as smaller file size
3) load the watermark.png into an image object
3) imagepaste the watermark to the image object and save it to /watermarked/
4) move the actual file to /original/

Then the header images are retrieved from /watermarked/ as in the example
from before.

So I have a watermarked image, the same image minus the watermark and I have
the original if I ever want to run them back through for a new watermark or
something.


-Original Message-
From: Raymond Camden [mailto:rcam...@gmail.com] 
Sent: Friday, June 04, 2010 8:09 AM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


http://www.coldfusionjedi.com/index.cfm/2010/6/4/Automating-watermarking-of-
images-with-ColdFusion


On Fri, Jun 4, 2010 at 6:40 AM, Raymond Camden rcam...@gmail.com wrote:
 Code is written - just ran into some other stuff yesterday which
 prevented me from blogging it. Will be the first thing I do once I get
 to work today. :)

 On Thu, Jun 3, 2010 at 5:02 PM, Bobby Hartsfield bo...@acoderslife.com
wrote:

 I wouldn't mind taking a look at what you put together for an event
gateway
 if the offer still stands.


 -Original Message-
 From: Raymond Camden [mailto:rcam...@gmail.com]
 Sent: Thursday, June 03, 2010 12:01 PM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 FYI, I've got some sample code to show how you can use a scheduled
 task to do this, or an event gateway.


 On Thu, Jun 3, 2010 at 10:48 AM, DURETTE, STEVEN J (ATTASIAIT)
 sd1...@att.com wrote:

 Why don't you use a hybrid... ?Drop the files in a directory, then when
 it's that files turn, check to see if a file of the same name is in a
 subdirectory called watermarked (or something like that). If it is just
 serve up the watermarked file. ?If not have the process create the
 watermarked file and put it in the watermarked directory.

 This allows you the flexibility of dropping files in there without
 worrying about it and it will speed up the process because the older
 files will be static watermarked, and you still have the originals if
 you ever need un-watermarked files.

 Steve


 -Original Message-
 From: Bobby Hartsfield [mailto:bo...@acoderslife.com]
 Sent: Thursday, June 03, 2010 9:50 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 I gave up. Nothing that resolved the issue was a valid long term
 solution. I've watermarked the images manually and removed all of the
 code to handle it on the fly.

 I'll still use it in a tool that watermarks the images as I upload them
 I guess.

 So now it is very simple...

 cfdirectory name=variables.mastImages action=list
 directory=#expandPath('/images/mastimages/')# filter=*.jpg /

 cfset variables.mastImg = randRange(1,variables.mastImages.recordcount)
 /

 cfheader name=Content-Disposition value=inline;
 #variables.mastImages['name'][variables.mastImg]#

 cfcontent
 type=image/jpg reset=true file=#expandpath('/images/mastimages/'
  variables.mastImages['name'][variables.mastImg])# /

 Thanks for all the input.











 



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334303
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-03 Thread Bobby Hartsfield

I gave up. Nothing that resolved the issue was a valid long term
solution. I've watermarked the images manually and removed all of the
code to handle it on the fly.

I'll still use it in a tool that watermarks the images as I upload them I guess.

So now it is very simple...

cfdirectory name=variables.mastImages action=list 
directory=#expandPath('/images/mastimages/')# filter=*.jpg /

cfset variables.mastImg = randRange(1,variables.mastImages.recordcount) /

cfheader name=Content-Disposition value=inline; 
#variables.mastImages['name'][variables.mastImg]#

cfcontent
type=image/jpg reset=true file=#expandpath('/images/mastimages/'
 variables.mastImages['name'][variables.mastImg])# /

Thanks for all the input.





~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334263
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-03 Thread DURETTE, STEVEN J (ATTASIAIT)

Why don't you use a hybrid...  Drop the files in a directory, then when
it's that files turn, check to see if a file of the same name is in a
subdirectory called watermarked (or something like that). If it is just
serve up the watermarked file.  If not have the process create the
watermarked file and put it in the watermarked directory.

This allows you the flexibility of dropping files in there without
worrying about it and it will speed up the process because the older
files will be static watermarked, and you still have the originals if
you ever need un-watermarked files.

Steve


-Original Message-
From: Bobby Hartsfield [mailto:bo...@acoderslife.com] 
Sent: Thursday, June 03, 2010 9:50 AM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


I gave up. Nothing that resolved the issue was a valid long term
solution. I've watermarked the images manually and removed all of the
code to handle it on the fly.

I'll still use it in a tool that watermarks the images as I upload them
I guess.

So now it is very simple...

cfdirectory name=variables.mastImages action=list
directory=#expandPath('/images/mastimages/')# filter=*.jpg /

cfset variables.mastImg = randRange(1,variables.mastImages.recordcount)
/

cfheader name=Content-Disposition value=inline;
#variables.mastImages['name'][variables.mastImg]#

cfcontent
type=image/jpg reset=true file=#expandpath('/images/mastimages/'
 variables.mastImages['name'][variables.mastImg])# /

Thanks for all the input.







~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334264
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-03 Thread Raymond Camden

FYI, I've got some sample code to show how you can use a scheduled
task to do this, or an event gateway.


On Thu, Jun 3, 2010 at 10:48 AM, DURETTE, STEVEN J (ATTASIAIT)
sd1...@att.com wrote:

 Why don't you use a hybrid...  Drop the files in a directory, then when
 it's that files turn, check to see if a file of the same name is in a
 subdirectory called watermarked (or something like that). If it is just
 serve up the watermarked file.  If not have the process create the
 watermarked file and put it in the watermarked directory.

 This allows you the flexibility of dropping files in there without
 worrying about it and it will speed up the process because the older
 files will be static watermarked, and you still have the originals if
 you ever need un-watermarked files.

 Steve


 -Original Message-
 From: Bobby Hartsfield [mailto:bo...@acoderslife.com]
 Sent: Thursday, June 03, 2010 9:50 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 I gave up. Nothing that resolved the issue was a valid long term
 solution. I've watermarked the images manually and removed all of the
 code to handle it on the fly.

 I'll still use it in a tool that watermarks the images as I upload them
 I guess.

 So now it is very simple...

 cfdirectory name=variables.mastImages action=list
 directory=#expandPath('/images/mastimages/')# filter=*.jpg /

 cfset variables.mastImg = randRange(1,variables.mastImages.recordcount)
 /

 cfheader name=Content-Disposition value=inline;
 #variables.mastImages['name'][variables.mastImg]#

 cfcontent
 type=image/jpg reset=true file=#expandpath('/images/mastimages/'
  variables.mastImages['name'][variables.mastImg])# /

 Thanks for all the input.







 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334267
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-03 Thread UXB Internet

 You are right though, I am most likely headed to a solution that involves
 watermarking the images permanently.

If the images are never going to be used on the site without a watermark
then you will save substantial processing time by doing so.  We have a
website that allows people to upload a picture which we mark, then they can
caption them aka lolcats.com style.  So a particular image could have many
different captions marked on it. 

When I first designed it all watermarks were on the fly but after a few days
of testing I found I was bogging the server down with extensive processing
even though as you say there was a satisfaction of the magic behind it.  Now
instead we mark the images once and save copies and reference them.  It
takes up more space but hard drive space was a lot cheaper than more
processing power.

You can see it here: http://www.lameorgame.com 


Dennis Powers
UXB Internet - A Website Design  Hosting Company
P.O. Box 6028
Wolcott, CT 06716
203-879-2844
http://www.uxbinternet.com




~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334274
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-03 Thread Bobby Hartsfield

I've tried to reply to this thread three times to explain what I ended up
with but they just aren't coming through... lets try again...


Basically, I gave up. Nothing that resolved the issue was a valid long term
solution. I've watermarked the images manually and removed all of the code
to handle it on the fly.

I'll still use it in a code that watermarks the images as I upload them I
guess.

So now it is VERY simple...

cfdirectory name=variables.mastImages action=list
directory=#expandPath('/images/mastimages/')# filter=*.jpg /
cfset variables.mastImg = randRange(1,variables.mastImages.recordcount) /

cfheader name=Content-Disposition value=inline;
#variables.mastImages['name'][variables.mastImg]#
cfcontent type=image/jpg reset=true
file=#expandpath('/images/mastimages/' 
variables.mastImages['name'][variables.mastImg])# /

Thanks for all the input and ideas. Much appreciated.






-Original Message-
From: UXB Internet [mailto:denn...@uxbinternet.com] 
Sent: Thursday, June 03, 2010 1:51 PM
To: cf-talk
Subject: RE: imageRead plus imagepaste plus imageGetBlob issue


 You are right though, I am most likely headed to a solution that involves
 watermarking the images permanently.

If the images are never going to be used on the site without a watermark
then you will save substantial processing time by doing so.  We have a
website that allows people to upload a picture which we mark, then they can
caption them aka lolcats.com style.  So a particular image could have many
different captions marked on it. 

When I first designed it all watermarks were on the fly but after a few days
of testing I found I was bogging the server down with extensive processing
even though as you say there was a satisfaction of the magic behind it.  Now
instead we mark the images once and save copies and reference them.  It
takes up more space but hard drive space was a lot cheaper than more
processing power.

You can see it here: http://www.lameorgame.com 


Dennis Powers
UXB Internet - A Website Design  Hosting Company
P.O. Box 6028
Wolcott, CT 06716
203-879-2844
http://www.uxbinternet.com






~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334293
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-03 Thread Bobby Hartsfield

Whether or not I would use them somewhere else is yet to be determined
really. I did like having the non-watermarked versions just incase though,
or if I wanted to change the watermark, all I had to do was upload a new
watermark.png.

I'm sure I'll end up with a mix of everything. It just won't be on the fly.

Steven's suggestion was something I considered; once the image's turn comes
around, if it hasn't been watermarked, do so, save it, display it. This way
I still have an original and a watermarked. Then, if I decide to change the
watermark, I can just upload a new one and call some backend process to
batch watermark them again.

The downside is obviously that it isn't all just magic and that I'll be
storing doubles. The upside is, I won't have to keep up with a masthead.psd
file for when I want to change the watermark :-)

Again, thanks for all the input and ideas.



-Original Message-
From: UXB Internet [mailto:denn...@uxbinternet.com] 
Sent: Thursday, June 03, 2010 1:51 PM
To: cf-talk
Subject: RE: imageRead plus imagepaste plus imageGetBlob issue


 You are right though, I am most likely headed to a solution that involves
 watermarking the images permanently.

If the images are never going to be used on the site without a watermark
then you will save substantial processing time by doing so.  We have a
website that allows people to upload a picture which we mark, then they can
caption them aka lolcats.com style.  So a particular image could have many
different captions marked on it. 

When I first designed it all watermarks were on the fly but after a few days
of testing I found I was bogging the server down with extensive processing
even though as you say there was a satisfaction of the magic behind it.  Now
instead we mark the images once and save copies and reference them.  It
takes up more space but hard drive space was a lot cheaper than more
processing power.

You can see it here: http://www.lameorgame.com 


Dennis Powers
UXB Internet - A Website Design  Hosting Company
P.O. Box 6028
Wolcott, CT 06716
203-879-2844
http://www.uxbinternet.com






~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334294
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-03 Thread Bobby Hartsfield

Imagine that, the first Google result for ColdFusion directory monitor :-)

http://archive.thedevweb.com/thedevweb-26-20071031DirectoryWatcherColdFusion
ImageManipulation.html


-Original Message-
From: Raymond Camden [mailto:rcam...@gmail.com] 
Sent: Thursday, June 03, 2010 12:01 PM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


FYI, I've got some sample code to show how you can use a scheduled
task to do this, or an event gateway.


On Thu, Jun 3, 2010 at 10:48 AM, DURETTE, STEVEN J (ATTASIAIT)
sd1...@att.com wrote:

 Why don't you use a hybrid... ?Drop the files in a directory, then when
 it's that files turn, check to see if a file of the same name is in a
 subdirectory called watermarked (or something like that). If it is just
 serve up the watermarked file. ?If not have the process create the
 watermarked file and put it in the watermarked directory.

 This allows you the flexibility of dropping files in there without
 worrying about it and it will speed up the process because the older
 files will be static watermarked, and you still have the originals if
 you ever need un-watermarked files.

 Steve


 -Original Message-
 From: Bobby Hartsfield [mailto:bo...@acoderslife.com]
 Sent: Thursday, June 03, 2010 9:50 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 I gave up. Nothing that resolved the issue was a valid long term
 solution. I've watermarked the images manually and removed all of the
 code to handle it on the fly.

 I'll still use it in a tool that watermarks the images as I upload them
 I guess.

 So now it is very simple...

 cfdirectory name=variables.mastImages action=list
 directory=#expandPath('/images/mastimages/')# filter=*.jpg /

 cfset variables.mastImg = randRange(1,variables.mastImages.recordcount)
 /

 cfheader name=Content-Disposition value=inline;
 #variables.mastImages['name'][variables.mastImg]#

 cfcontent
 type=image/jpg reset=true file=#expandpath('/images/mastimages/'
  variables.mastImages['name'][variables.mastImg])# /

 Thanks for all the input.







 



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334296
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Leigh _

Luck of the draw maybe, but I did not experience the problem (aside from 
pixalation). Though I did get a sporadic error message when viewing 
masthead.cfm directly.  Every few refreshes, the following text appears:

The image http://acoderslife.com/images/masthead.cfm; cannot be displayed, 
because it contains errors.

But only for a second or two. Then the header image appears as expected.


~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334219
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Raymond Camden

Never saw the issue myself. You know - as fast as CF is - there really
is no reason to be doing this on every request. When you've made the
watermarked version, you should save it. In fact, I'd just do a one
time script to generate them and then dynamically pick from there.

Also - I'd consider adding a cfheader above the cfcontent.


On Wed, Jun 2, 2010 at 12:29 AM, Leigh _ cfsearch...@yahoo.com wrote:

 Luck of the draw maybe, but I did not experience the problem (aside from 
 pixalation). Though I did get a sporadic error message when viewing 
 masthead.cfm directly.  Every few refreshes, the following text appears:

 The image http://acoderslife.com/images/masthead.cfm; cannot be displayed, 
 because it contains errors.

 But only for a second or two. Then the header image appears as expected.


 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334221
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Bobby Hartsfield

Thanks for the ideas Azadi,

Sticking the CSS in the head between style tags alone didn't work but adding
?nocache=#hash(now())# to the masthead.cfm URL did resolve it.

I didn't even think to try another way of writing the image out like you
suggested. I'll give that a shot when I get home this afternoon.


-Original Message-
From: Azadi Saryev [mailto:azadi.sar...@gmail.com] 
Sent: Tuesday, June 01, 2010 11:41 PM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 browser css/images caching? i did see the problem you described on the
link you posted...

what if you put the css declaration into the page (instead of external
stylesheet) and add a random url param to the bg image url?
style type=text/css
#masthead {background:
url(/images/masthead.cfm?x=cfoutput#createuuid()#/cfoutput) no-repeat;}
/style

i did a very similar thing on a a couple of site, but i had random url
params added to img urls and never saw the problem you see...
i also served the images using a script like this instead of cfcontent
tag:

cfscript
oImg = toBinary(toBase64(objImage)); // can probably use oImg =
imagegetblob(objImage); in your case
context = getPageContext();
context.setFlushOutput(false);
response = context.getResponse().getResponse();
out = response.getOutputStream();
response.setContentType(image/jpeg);
response.setContentLength(arrayLen(oImg));
out.write(oImg);
out.flush();
//response.reset(); //optional for problems
out.close();
/cfscript

hth

Azadi


On 02/06/2010 11:02, Bobby Hartsfield wrote:
 I've got this issue that is driving me batty.

 ... 
 ...
 ...

 



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334224
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Bobby Hartsfield

Interesting. I tried from a few different browsers on Mac and PC... and from
home and work. I was able to replicate it in all attempts. I even had a
couple of friends try from other locations and they too saw the issue.

I've yet to see the error you spotted though. I don't see anything that
appears related in the error logs either. I'll keep an eye out for that one.

Thanks for looking.

-Original Message-
From: Leigh _ [mailto:cfsearch...@yahoo.com] 
Sent: Wednesday, June 02, 2010 1:30 AM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


Luck of the draw maybe, but I did not experience the problem (aside from
pixalation). Though I did get a sporadic error message when viewing
masthead.cfm directly.  Every few refreshes, the following text appears:

The image http://acoderslife.com/images/masthead.cfm; cannot be displayed,
because it contains errors.

But only for a second or two. Then the header image appears as expected.




~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334225
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Bobby Hartsfield

Hi Ray, Permanently watermarking the images is my last option. The way it
(sorta) works now is preferable if I can get it to work correctly. Right
now, I can just FTP the image to the directory and it starts showing up
(complete with watermark) without really doing anything.

I know, I'm lazy :-)

The cfheader was in there at some point. I must have left it out on one of
my failed attempts at fixing this. Thanks for pointing it out.

@Leigh, yeah, the pixilation is my fault. I lowered the quality of the
images drastically to see if file size was playing a factor.

-Original Message-
From: Raymond Camden [mailto:rcam...@gmail.com] 
Sent: Wednesday, June 02, 2010 6:22 AM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


Never saw the issue myself. You know - as fast as CF is - there really
is no reason to be doing this on every request. When you've made the
watermarked version, you should save it. In fact, I'd just do a one
time script to generate them and then dynamically pick from there.

Also - I'd consider adding a cfheader above the cfcontent.


On Wed, Jun 2, 2010 at 12:29 AM, Leigh _ cfsearch...@yahoo.com wrote:

 Luck of the draw maybe, but I did not experience the problem (aside from
pixalation). Though I did get a sporadic error message when viewing
masthead.cfm directly. ?Every few refreshes, the following text appears:

 The image http://acoderslife.com/images/masthead.cfm; cannot be
displayed, because it contains errors.

 But only for a second or two. Then the header image appears as expected.


 



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334227
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Raymond Camden

Yeah but there is no reason you can't continue to do that. You can FTP
to dir A. Use a cfscheduled task to scan A and copy/watermark new
images and then move it to B.

So you get the convenience of being able to add new images whenever -
and you get the performance of only having to watermark once. :)


On Wed, Jun 2, 2010 at 7:14 AM, Bobby Hartsfield bo...@acoderslife.com wrote:

 Hi Ray, Permanently watermarking the images is my last option. The way it
 (sorta) works now is preferable if I can get it to work correctly. Right
 now, I can just FTP the image to the directory and it starts showing up
 (complete with watermark) without really doing anything.

 I know, I'm lazy :-)

 The cfheader was in there at some point. I must have left it out on one of
 my failed attempts at fixing this. Thanks for pointing it out.

 @Leigh, yeah, the pixilation is my fault. I lowered the quality of the
 images drastically to see if file size was playing a factor.

 -Original Message-
 From: Raymond Camden [mailto:rcam...@gmail.com]
 Sent: Wednesday, June 02, 2010 6:22 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 Never saw the issue myself. You know - as fast as CF is - there really
 is no reason to be doing this on every request. When you've made the
 watermarked version, you should save it. In fact, I'd just do a one
 time script to generate them and then dynamically pick from there.

 Also - I'd consider adding a cfheader above the cfcontent.


 On Wed, Jun 2, 2010 at 12:29 AM, Leigh _ cfsearch...@yahoo.com wrote:

 Luck of the draw maybe, but I did not experience the problem (aside from
 pixalation). Though I did get a sporadic error message when viewing
 masthead.cfm directly. ?Every few refreshes, the following text appears:

 The image http://acoderslife.com/images/masthead.cfm; cannot be
 displayed, because it contains errors.

 But only for a second or two. Then the header image appears as expected.






 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334228
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Bobby Hartsfield

Yeah, but then I wouldn't get the satisfaction in knowing that it is magic
every time I load the page! Haha

You are right though, I am most likely headed to a solution that involves
watermarking the images permanently.

-Original Message-
From: Raymond Camden [mailto:rcam...@gmail.com] 
Sent: Wednesday, June 02, 2010 8:27 AM
To: cf-talk
Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


Yeah but there is no reason you can't continue to do that. You can FTP
to dir A. Use a cfscheduled task to scan A and copy/watermark new
images and then move it to B.

So you get the convenience of being able to add new images whenever -
and you get the performance of only having to watermark once. :)


On Wed, Jun 2, 2010 at 7:14 AM, Bobby Hartsfield bo...@acoderslife.com
wrote:

 Hi Ray, Permanently watermarking the images is my last option. The way it
 (sorta) works now is preferable if I can get it to work correctly. Right
 now, I can just FTP the image to the directory and it starts showing up
 (complete with watermark) without really doing anything.

 I know, I'm lazy :-)

 The cfheader was in there at some point. I must have left it out on one of
 my failed attempts at fixing this. Thanks for pointing it out.

 @Leigh, yeah, the pixilation is my fault. I lowered the quality of the
 images drastically to see if file size was playing a factor.

 -Original Message-
 From: Raymond Camden [mailto:rcam...@gmail.com]
 Sent: Wednesday, June 02, 2010 6:22 AM
 To: cf-talk
 Subject: Re: imageRead plus imagepaste plus imageGetBlob issue


 Never saw the issue myself. You know - as fast as CF is - there really
 is no reason to be doing this on every request. When you've made the
 watermarked version, you should save it. In fact, I'd just do a one
 time script to generate them and then dynamically pick from there.

 Also - I'd consider adding a cfheader above the cfcontent.


 On Wed, Jun 2, 2010 at 12:29 AM, Leigh _ cfsearch...@yahoo.com wrote:

 Luck of the draw maybe, but I did not experience the problem (aside from
 pixalation). Though I did get a sporadic error message when viewing
 masthead.cfm directly. ?Every few refreshes, the following text appears:

 The image http://acoderslife.com/images/masthead.cfm; cannot be
 displayed, because it contains errors.

 But only for a second or two. Then the header image appears as expected.






 



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334229
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Raymond Camden

On Wed, Jun 2, 2010 at 7:38 AM, Bobby Hartsfield bo...@acoderslife.com wrote:

 Yeah, but then I wouldn't get the satisfaction in knowing that it is magic
 every time I load the page! Haha

Perfect! ;)

 You are right though, I am most likely headed to a solution that involves
 watermarking the images permanently.

Yeah - I've seen - sometimes - rarely really - CF take a _real_ long
time to process certain images. So I always try to do these types of
operations one time if i can.

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334230
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


RE: imageRead plus imagepaste plus imageGetBlob issue

2010-06-02 Thread Leigh

 I've yet to see the error you spotted though. 

I still see it with FF 3.6.4. But it only seems to happen when the header was 
viewed directly, and the image always shows up within a second. It might be a 
browser issue. I see a few references to similar problems with FF. 

Though I myself would probably go with Raymond's suggestion to watermark once, 
just to save some processing ;) But I am glad the random hash() seems to do the 
trick.

-Leigh


  


~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334244
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: imageRead plus imagepaste plus imageGetBlob issue

2010-06-01 Thread Azadi Saryev

 browser css/images caching? i did see the problem you described on the
link you posted...

what if you put the css declaration into the page (instead of external
stylesheet) and add a random url param to the bg image url?
style type=text/css
#masthead {background:
url(/images/masthead.cfm?x=cfoutput#createuuid()#/cfoutput) no-repeat;}
/style

i did a very similar thing on a a couple of site, but i had random url
params added to img urls and never saw the problem you see...
i also served the images using a script like this instead of cfcontent
tag:

cfscript
oImg = toBinary(toBase64(objImage)); // can probably use oImg =
imagegetblob(objImage); in your case
context = getPageContext();
context.setFlushOutput(false);
response = context.getResponse().getResponse();
out = response.getOutputStream();
response.setContentType(image/jpeg);
response.setContentLength(arrayLen(oImg));
out.write(oImg);
out.flush();
//response.reset(); //optional for problems
out.close();
/cfscript

hth

Azadi


On 02/06/2010 11:02, Bobby Hartsfield wrote:
 I've got this issue that is driving me batty.

 ... 
 ...
 ...

 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334215
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm