HI,
I have a small contact form with the following fields
- First Name
- Last Name
- Mobile Number
- Photo
I am looking to store the image of this contact in the blob field of the database table. But it is not working.
Can you please guide?
Thanks !
HI,
I have a small contact form with the following fields
I am looking to store the image of this contact in the blob field of the database table. But it is not working.
Can you please guide?
Thanks !
You need to read the image file saved by the upload action then store the file data into a variable, you can do these 2 steps in 1 PHP action:
$file_path = $this->get("upload_action_name.path"); // you get this from the form debug, it will show you the file path
$file_data = file_get_contents($file_path, true);
return base64_encode($file_data);
then use {var:php_action_name} in your Save Data fields