close ad
WARNING PC USERS: Do Not Install the DREAMWEAVER CC 2017 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Image Upload Querstion

Thread began 5/20/2015 9:31 am by Paul | Last modified 5/28/2015 6:40 pm by Ray Borduin | 886 views | 7 replies |

PaulBeta Tester

Image Upload Querstion

I have created an upload page.

I need to insert the image params into a table and then show the uploaded image on the same page.
The user can only submit upto a max of 12 images.

1. What order should my code be in?
2. how best should i restrict the upload to 12 (on the Upload or insert user behavior?

Thanks, Paul.

Sign in to reply to this post

Ray BorduinWebAssist

The order would be the upload code and then the insert or update into the database.

How you would limit it would depend on the database structure and user experience you want to support.

You could insert a new row into a related table for each image and add a recordset to determine how many rows they have already inserted and then don't allow another insert once they reach 12 with server validation... but there are a lot of other ways you could do it depending on how you wanted it to work.

Sign in to reply to this post

PaulBeta Tester

Hi Ray, thanks for replying.

I think server validation is more robust than hiding the upload form when the recordset hits 12.
What would be my approach using the server validation on that page?

Sign in to reply to this post

Ray BorduinWebAssist

You would still add the recordset, then apply number validation to the number of rows variable with a max value of 12.

Sign in to reply to this post

PaulBeta Tester

Server Validation question

im trying to apply the following validation to an image upload that ive built using DB

successful, failed, type, size, width and height.

I'm not sure whether i should be using their error code values when building the server bevaiours aswell and if so how they should be included in each 'server validation show: region if...'

I've looked for a WA help vid, but unable find - File attached in PM.

Sign in to reply to this post

Ray BorduinWebAssist

Since you are validating a value from the recordset, you will have to manually move the validation code below the recordset.

So take the code on lines: 9-23 and move it below the recordsets... probably just above the doctype tag.

Sign in to reply to this post

PaulBeta Tester

Thanks Ray, that makes sense.

I'm struggling to implement the upload limit validation.

My current thinking is show the upload form whilst my 'count' recordset is empty (not equal to twelve)
However, if i use the 'show if' validation and select the pass validation option, my form is hidden from scratch.

What logic works for this scenario?



Also as a seperate but related issue, i note that the narrative on the wizard refers to deleting a file rather than uploading it.
see screenshot attached.... or have i missed something?

Sign in to reply to this post

Ray BorduinWebAssist

Looks like we missed something, not you... I'll update the text for the next release.

I would think you would show the upload field if it passed validation using the validation show if... not based on the recordset directly.

Sign in to reply to this post

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...