Jump to:

7935 Posts in 1536 Topics by 943 members

DataObjectManager Module

SilverStripe Forums » DataObjectManager Module » Issue with Uploadify

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1192 Views
  • Arctos
    Avatar
    Community Member
    3 Posts

    Issue with Uploadify Link to this post

    After scouring the forums, both the Silverstripe and Uploadify; I wasn't sure which to specifically diagnose.

    Using the latest Silverstripe (2.4.5), latest DataObjectManager and Uploadify (since 4/1/2011):

    In attempts to upload anything, I end up with a white page, except for "Closing..."

    With the following notable firefox error console errors:

    Error: parent.jQuery is not a function
    Source File: http://www.bengaltownship.org/beta/admin/assets/EditForm/field/Files/UploadifyForm?SecurityID=cd93d5a4242f540f89d1908a2a91a8fb4a2ed195&ctf[Files][start]=0&ctf[Files][per_page]=10&ctf[Files][showall]=0&ctf[Files][sort]=SortOrder&ctf[Files][sort_dir]=&ctf[Files][search]=&ctf[Files][filter]=&ctf[Files][view]=
    Line: 24

    Warning: Form contains a file input, but is missing method=POST and enctype=multipart/form-data on the form. The file will not be sent.
    Source File: http://www.clientwebsite.org/beta/admin/assets/EditForm/field/File/upload?SecurityID=cd93d5a4242f540f89d1908a2a91a8fb4a2ed195 Line: 0

    Interestingly enough, it seems to have uploaded the files... despite the nearly-White-Screen-Of-Death. My local WAMP version, wasn't able to get that far. I've worked with DataObjectManager and Uploadify with success in the past, so as far as I know it isn't blatant user error.

    Thoughts?

  • UncleCheese
    Avatar
    4085 Posts

    Re: Issue with Uploadify Link to this post

    Yeah, it looks like the Form class is hardcoded to look for FileField subclasses. That's a drag. No way to override it, either.

       function FormEncType() {
          if(is_array($this->fields->dataFields())){
             foreach($this->fields->dataFields() as $field) {
                if(is_a($field, "FileField")) return "multipart/form-data";
             }
          }
          return "application/x-www-form-urlencoded";
       }

  • Arctos
    Avatar
    Community Member
    3 Posts

    Re: Issue with Uploadify Link to this post

    I appreciate the reply,

    ..but where specifically are you pulling this snippet from? Silverstripe Core? Uploadify? DataObjectManager? ... and the fact that there "no way to override it", no band-aids? Because in working with different site, this time utilizing your Image_Gallery.

    Same error, I feel like I must be missing something.

    Thanks,

  • UncleCheese
    Avatar
    4085 Posts

    Re: Issue with Uploadify Link to this post

    That's in Form.php.

    It's not really an error, it's just a warning. Ideally you want the multipart enctype on a form with a file input, but it's kind of a moot point since Flash replaces the file input with its own interface.

    1192 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.