Quantcast
Channel: Joomla! Forum - community, help and support
Viewing all articles
Browse latest Browse all 1433

Extensions for Joomla! 5.x • Chronoforms 8 - Unable to Upload Images to BLOB field in database (Plain form created directly using PHP is working fine

$
0
0
I am new to Joomla and Chronoforms. I think I may be missing something trivial to accomplish the task of uploading a photo to a blob field in the DB.

Not sure if this is the right forum. Could not see much info in the Chronoforms 8 forum or FAQ or any documentation.

----------------------------------

I have created a simple form that contains three fields.

name
email
photo
Photo is a blob field in DB and would like to store the images into this database field.

I have double checked the permissions to write to /tmp/ folder. Its fine.

Joomla Global Config is set correctly to /tmp/ folder (See attached screenshot)


With debug info ON, I see this debug info on the webpage when a file is uploaded.

Array
(
[photo] => Array
(
[name] => BestPrice - Copy.jpg
[full_path] => BestPrice - Copy.jpg
[type] => image/jpeg
[tmp_name] => /tmp/php1SCniu
[error] => 0
[size] => 15815
)

)
upload_max_filesize: 2048M
upload_tmp_dir:
SMTP: localhost
smtp_port: 25
memory_limit: 2048M
post_max_size: 2048M
max_execution_time: 360

FILE element is configured in the form as shown in the attachment.

I have tried to write the Custom PHP code in submit to convert the file data into a stream so I can upload to DB.
But this PHP is not able to access the temp file since temp file is not written as part of Chronoform processing.

Can you let me know how can I accomplish this need of uploading a file to database.

Note: I have written a plain PHP form with db processing and is able to upload the file to database. No issue. With Chronoforms 8, I am not able to do it.

Looking forward for your support.

Thanks,

Prashanth

Statistics: Posted by prashantsp — Sun Aug 04, 2024 11:39 am



Viewing all articles
Browse latest Browse all 1433

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>