close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

validation on multipart form not working

Thread begun 3/31/2009 10:03 am by aaron5263 | Last modified 8/25/2010 1:14 am by info368164 | 5188 views | 8 replies |

aaron5263

validation on multipart form not working

Im trying to apply the server validation behavior to a form that has an image upload field in it. Form is a multipart/form-data.

it does not work. i get an object not found when doing the validation.
does this server behavior work with multipart forms?

Thanks!
Aaron

Sign in to reply to this post

Ray BorduinWebAssist

Are you using ASP? The problem is probably the way you are referring to form elements. You need to refer to them differently with asp multipart forms. What are you using for your upload? It will include a solution for how to refer to form elements.

Sign in to reply to this post
Did this help? Tips are appreciated...

aaron5263

using dmx asp pureupload 3.0. yes using asp.
I applied aspupload to the page first. then applied the server validations behavior.
I can see the upload form elements within the webassist server interface. but it always now submits the form without throwing errors.

I have also mail uploaded files dmx extension applied on the page.

Sign in to reply to this post

Ray BorduinWebAssist

You would have to check the pureuplaod documentation for what to replace Request.Form with... most likely it is something like UploadObj.Form. Once you figure out the right syntax, you can probably just do a find and replace.

Sign in to reply to this post
Did this help? Tips are appreciated...

aaron5263

still not working

it still doesnt work. It does not throw an error but just lets the form submit without all fields validated. There are no request.form elements anywhere in the page.

Are you able to get server validations to work with multipart forms?

Thanks

Sign in to reply to this post

Ray BorduinWebAssist

Yes. We do this in our Powerstore sample but that is php. The only thing that changes when you go to multipart forms is the way you refer to their values.

Is using our Digital File Pro an option for you? That would make me more familiar with your upload code and make it easier to find the solution. It is definitely possible, but like I said you may have to update a few lines of code where Request.Form is used.

Sign in to reply to this post
Did this help? Tips are appreciated...

eric341232

Powerstore sample

I am also experiencing this difficulty with php and multipart forms. Can you tell me where I can find this Powerstore sample or, here, can you jot down how I need to refer to form values to get validation in the context of a multipart enctype form to work? That would be great.

Sign in to reply to this post

Ray BorduinWebAssist

php doesn't have this difficulty with multipart forms. Please start a new thread describing your exact problem and we can try to help you through it.

Sign in to reply to this post
Did this help? Tips are appreciated...

info368164

I have same identical problem with the same extension (PAU)
My solution (ASP Classic and VBScript):

Validation toolkit:
.........................
if (cStr(UploadFormRequest("Submit")) <> "") then
WAFV_Redirect = "mypage.asp"
Session("WAVT_COOPcompleta_Errors") = ""
if (WAFV_Redirect = "") then
WAFV_Redirect = cStr(Request.ServerVariables("SCRIPT_NAME"))
end if
WAFV_Errors = ""
WAFV_Errors = WAFV_Errors & WAValidateRQ(cStr(UploadFormRequest("textfield1")) & "",false,1)
WAFV_Errors = WAFV_Errors & WAValidateRQ(cStr(UploadFormRequest("textfield2")) & "",true,2)

if (WAFV_Errors<> "") then
PostResult WAFV_Redirect,WAFV_Errors,"mypage"
end if
end if
...............

for to fill the form with imputed data i use the sessions:
..........
if (cStr(UploadFormRequest("Submit")) <> "") then
Session("text1")=UploadFormRequest("textfield1")
Session("text2")=UploadFormRequest("textfield2")
end if
...........

Regards
Luca

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