Definitely get the image.cfc which is at opensourcecf.com (I think).  
Here is some code that I have on a personal site to manage a photo 
album.  This is an upload utility so when the user uploads a file, they 
can preview it if they want.  This is just the code to preview it which 
does the dynamic thumbnail that you are looking for.

<cfoutput>
<cfset folder = tools.getFolder(form.category)>
<b>#file.serverfile#</b><br>
<cfif not 
fileexists("D:\websites\reynacho.net\images\thumbs\thumb_#file.serverfile#")>
    <cfoutputpath = 
"D:\websites\reynacho.net\images\thumbs\thumb_#file.serverfile##
    <cfset img_read = imageTools.resize("", inputpath, outputpath, 300, 0)>
    <cfif img_read.errorcode NEQ 0>
        <img src="http://reynacho.net/images/#folder#/#file.serverfile#"; 
width="300">
        <!--- do nothing --->
    <cfelse>
        <img 
src="http://reynacho.net/images/thumbs/thumb_#file.serverfile#";>
    </cfif>
<cfelse>
    <img src="http://reynacho.net/images/thumbs/thumb_#file.serverfile#";>
</cfif>
</cfoutput>

Doug Brown wrote:
> Probably the best way that I can think of is to load the images into a JS
> array and then give your select a size attribute from yourQuery.recordCount.
> Have JS stick the image in a <div> when an images is selected.
>
>
> Hope this helps
>
>
> Doug
>
> ----- Original Message ----- 
> From: "Pete" <[EMAIL PROTECTED]>
> To: "CF-Talk" <[email protected]>
> Sent: Monday, October 02, 2006 3:37 AM
> Subject: Select drop down
>
>
>   
>> Hi there
>>
>> I am trying to complete the development of an application.
>>
>> In one of the programs where a user is entering data I am asking a user to
>> enter details of a photo that will be added to a record.
>>
>> So far I have  a query that will select all available photos that are
>> available.
>>
>> Here is the query.
>>
>> <cfquery name="qgetphotonames" datasource="#Request.DSN#">
>> select *
>> from photos
>> order by photothbname
>> </cfquery>
>>
>> Then I have in the main part of the program
>>
>> <tr>
>>     <td valign="top">&nbsp;
>>       <select name="photoid">
>>         <cfoutput query="qgetphotonames">
>>           <option value="#photoid#">#photothbname# </option>
>>         </cfoutput>
>>       </select>&nbsp;&nbsp;</td>
>>     </tr>
>>
>> What I am trying to do is the following.  As well as displaying the
>> photo.name  I would also like to display the thumbnail picture so a user
>>     
> can
>   
>> actually see the thumbnail when selecting the picture to use.
>>
>> Wondering if anyone has any idea of how this can be done.
>>
>> Regards & thanks in advance.
>>
>> Pete
>>
>>
>>
>>
>>
>>
>>     
>
> 

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

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

Reply via email to