close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Adding thumbnails with image upload

Thread began 3/01/2010 3:21 pm by koneill385535 | Last modified 5/20/2010 10:38 pm by Jimmy Wu | 4819 views | 24 replies |

koneill385535

Adding thumbnails with image upload

Hi,

I followed this tutorial for uploading detail images and thumbnails at the same time in my insert page with DataAssist:

digital_file_pro_resize_images_ht.pdf

I already had an image upload button, but I wanted to change the server behavior to include a thumbnail. I tried editing the server behavior, but when I tested it out, it didn't provide the thumbnails in the results page. How do I get the results page to show a thumbnail without asking the user to upload two separate images?

Sign in to reply to this post

Ian

Store the name of the thumbnail in a separate field, and call that image on the thumbnail page.

Sign in to reply to this post

koneill385535

How do I store it in a separate field if I want it to simultaneously upload the image and the thumbnail? I've got it so it saves it in two separate folders with different sizes, I just don't know how to access the photo. I am attaching what I did with the Digital File Pro Upload Wizard.

Sign in to reply to this post

Dani Chankhour

You can just use the same image tag you have for the main image and just update the source attribute to use your thumbs folder instead:

<img src="thumgfolder/image.jpg" />

If you post your current image tag i can tell you what you need to change exactly.

Sign in to reply to this post

koneill385535

OK, I changed it around a little bit to where I thought it would work. It isn't quite right though. Here is my image tag:

images/product_thumb/<?php echo $row_WADAproducts["ProductImage"]; ?>

I am uploading the rough draft of the site so you can take a look at the code. I just uploaded the new insert and results page so you can try it out and look at the code.

I also am attaching what the result looks like.

Sign in to reply to this post

koneill385535

Oops, and the insert and results pages are these:

products_Insert.php

products_Results.php

Sign in to reply to this post

Dani Chankhour

OK, i think what you need to do is this:

images/product_thumb/<?php echo str_replace("detail", "thumb", $row_WADAproducts["ProductImage"]); ?>

Since the field in your database it probably named image_detail.jpg but you want o display image_thumb.jpg. So the above replacement will replace detail with thumb.

Sign in to reply to this post

koneill385535

Hmm... That didn't seem to work. It just brings up a missing image thing.


products_Results.php

Sign in to reply to this post

Dani Chankhour

I'm not able to view your product results page because it requires a log in. But what you can do is view the source of your image tag and see what is the resulting url that is being generated in the source attribute. and then we can compare it to what it actually needs to be.

please post back with the source of the <img> tag and what is the url needs to be to view the page.

Sign in to reply to this post

koneill385535

Ok, when I click on the picture in Dreamweaver, the field labeled src is this:

images/product_thumb/<?php echo str_replace("detail", "thumb", $row_WADAproducts["ProductImage"]); ?>

I'm not sure what it should be, or exactly where and what name the thumbnail is. I took off the restrict access behavior, so you can access the site now:

products_results.php

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...