0

Gurus out there, I get an error adding a file upload field in drupal 7 webforms, when enabling the "Form Processor File Url" wrapper, something like "Directory cmrfformprocessor://webform/my-name could not be created. Please make sure directory is writable".

I tried to create every directory combination under sites/default/files, but nothing helped. Made sites/ writable for apache-user recursively but no luck. Read the civimrf and cmrf_form_processor source code without getting a clue.

Could you help me out?

Drupal, all modules and CiviCRM are current stable versions.

1 Answer 1

0

I do not know, how this ever worked. Webform module checks for the schemed directory path always, even if - like in this case - the streamwrapper is mapped to an external API and not to the local filesystem.

So changing

public function mkdir($uri, $mode, $options) {
    return FALSE;
}

to

public function mkdir($uri, $mode, $options) {
    return TRUE;
}

in cmrf_form_processor_stream_wrapper.inc fixes the issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.