0

How to insert my uploaded files inside a custom table (as managed_file) after upload inside a custom form on DRupal 8 please ?

For moment, I have :

$form['images']['new']['local'] = array(
  '#title' => t('Upload Images'),
  '#type' => 'managed_file',

I need to use jquery, element_validate ? Other ? Thanks.

1 Answer 1

0

Don't. It's a fundamentally bad idea to store data in custom table in Drupal 8. There are enough APIs and no support for that. Of course, hooks are still there so you can implement hook_entity_presave and then take the field data and write it out... but just say no :)

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.