Forums / Developer / Forms using exbinaryfile or File datatype

Forms using exbinaryfile or File datatype

Author Message

Elena Jovanovska

Monday 07 June 2010 7:13:27 am

I need to create a form (that collect information from anonymous users) that has an upload field. I have used the predefined datatype File, but the file is not uploaded. Do I need to change some system settings or?? I need the same functionality of register form (the uploading image part) what should i do?

Steven E. Bailey

Monday 07 June 2010 8:51:39 am

Take a look at http://projects.ez.no/enhancedezbinaryfile

Certified eZPublish developer
http://ez.no/certification/verify/396111

Available for ezpublish troubleshooting, hosting and custom extension development: http://www.leidentech.com

Elena Jovanovska

Tuesday 08 June 2010 2:01:28 am

I can't make it work. It didn't want to upload the file it returns some error in the process of submition of the form.

Steven E. Bailey

Tuesday 08 June 2010 5:19:59 am

What version of ezpublish are you using?

Did you remember to change the form enctype to multipart/form-data?

<form method="post" action={"content/action"|ezurl} enctype="multipart/form-data">

Did you read the readme.txt and install.txt?

What was the specific error?

Certified eZPublish developer
http://ez.no/certification/verify/396111

Available for ezpublish troubleshooting, hosting and custom extension development: http://www.leidentech.com

Elena Jovanovska

Tuesday 08 June 2010 7:27:08 am

i got this error

Fatal error: Class 'eZDOMDocument' not found in D:\wamp\www\project_name\extension\enhancedezbinaryfile\datatypes\enhancedezbinaryfile\enhancedezbinaryfiletype.php on line 455
Fatal error: eZ Publish did not finish its request

Steven E. Bailey

Tuesday 08 June 2010 2:13:03 pm

Check ezinfo.php - do you have the latest version of enhancedbinaryfiletype - it should be 1.1?

This is line 455 of that file -

$doc = new DOMDocument( '1.0', 'utf-8' );

So, it shouldn't be eZDOMDocument.

Certified eZPublish developer
http://ez.no/certification/verify/396111

Available for ezpublish troubleshooting, hosting and custom extension development: http://www.leidentech.com

Steven E. Bailey

Wednesday 09 June 2010 12:32:25 am

It looks like you must have revision 2 of the datatype ( http://projects.ez.no/enhancedezbinaryfile/downloads ). That will stop working for any ezpublish installation above version 4.0.x. See changelog: Implemented enhancement #14309: Remove ezxml library. If you have upgraded your ezpublish installation, then get revision 3 from the download page.

Certified eZPublish developer
http://ez.no/certification/verify/396111

Available for ezpublish troubleshooting, hosting and custom extension development: http://www.leidentech.com

Vitaliya Rybakova

Tuesday 15 June 2010 5:53:48 am

Hello,

how type of form do you use? Is it php form, html form, servoy form, perl form or other type of form?