cancel
Showing results for 
Search instead for 
Did you mean: 

Product custom file upload

Product custom file upload

Hi all!!

I would like to know, how to magage the frontend part of product file upload option implemented in themes.

 

I know frontend html is found in (depending your theme):
app/design/frontend/default/default/template/catalog/product/view/options/type/file.phtml

 

Frontend javascript code in:
app/design/frontend/default/default/template/catalog/product/view/options.phtml

 

and inside node: config->global->catalog->product->options->custom->groups, in app/code/core/Mage/Catalog/etc/config.xml:

 

<file translate="label" module="adminhtml">

<label>File</label>

<render>adminhtml/catalog_product_edit_tab_options_type_file</render>

<types> <file translate="label" module="adminhtml">

<label>File Upload</label> </file> </types> </file>

 

This is perfect if you only want to upload a single file and you don't need to do anything else.

 

But I need to magage the file before upload, and I don't know how to implemente my own javascript code, because when I select or add to cart, nothing happends, I mean, I put "alert" on options.phtml, and my messages didn't appear.

 

I would like to know if it is possible select more than one file at once and where is the file saved, path or database table name.

 

Thank you in advance.

Greetings.