0

I'm new to Magento. I want to create an upload field on product view form just before the Add to Cart button for the end user to upload an image file before clicking Add to Cart button. How to show that field and how to upload the image in the file system. Please also mention what to add in which files to make it happen.

asked Oct 7, 2016 at 15:15

1 Answer 1

0

You can do this whole thing from your product edit page in admin panel.

Product Edit> Customizable Options> Add Option> Select "File" from option type dropdown

answered Oct 7, 2016 at 18:06
2
  • Thanks for a reply @Nahid. that thing worked but I'm getting following error Cannot read contents from file "C:/Users/Nausif/AppData/Local/Temp/C:/xampp/tmp/php2CCA.tmp" Warning!file_get_contents(C:/Users/Nausif/AppData/Local/Temp/C:/xampp/tmp/php2CCA.tmp): failed to open stream: Invalid argument. Also this solution will put file attachment field per product level, I want that on a particular attribute set, so that I can get it on multiple products having same attribute set. Commented Oct 8, 2016 at 5:10
  • @Nausif Running Magento on Windows environment is not recommended at all. Magento has not event tested in windows environment. You may try Magento on virtual machine while you are using your favorite windows PC as host machine. Seems this error is some kind of permission related. You may try changing tmp directory in your php.ini file. As this is product custom option and not an product attribute so, you can not use this on a product attribute set. Commented Oct 10, 2016 at 0:43

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.