View Product Page

How to create general upload rules

In order to let the user upload one or more files and associated them with specific products in the cart, make sure the administrator first creates the specific upload rules in the plugin settings or on the product detail page.

The general rules apply to all the products of the shop, but you can however disable them from the product edit page.

If the upload button does not show: 

  • check the pages on which you enabled the file upload
  • make sure that you enabled the upload for the products and/or the order

To create a general rule, go to YITH > Uploads and click on the Add new rule button.

How to create a general upload rule

For each new rule you need to set:

  • label: text to describe the upload field.
  • allowed file extensions: if the uploaded file has a different extension, it will be rejected. Leave empty to allow any file extension.
  • maximum size allowed for the file.
  • allow notes: when enabled, the user will be able to type in a note that will be visible to the administrator in the order details.

Each rule will enable an upload option on the product. 

Assuming that we have created 2 upload rules, the user will have to add 2 files when purchasing.

Order with uploads - example

Upload rules management on simple products

By default, all the general rules apply to all the products of the shop unless you have disabled it from the product settings or if you have configured at least one new rule on the product. Let’s see how to do this.

Open the product detail page and click on the “Add new rule” button.

Set rules on the simple product

As for any new rule, you must specify the following parameters:

  • label: text to describe the upload field.
  • allowed file extensions: if the uploaded file has a different extension, it will be rejected. Leave empty to allow any file extension.
  • maximum size allowed for the file.
  • allow notes: when enabled, the user will be able to type in a note that will be visible to the administrator in the order details.

Assuming that we configured 4 general upload rules (therefore, 4 files) and 2 on the YITH Bag product, we expect to get 4 files as required for all the products in the cart and 2 for the YITH Bag product.Upload rule by product

 

If you want to prevent the customer from uploading any kind of file for a specific product, then, make sure you check the “Disable the upload” option on the product page.

Disable the upload

How to manage the uploads on variable products

When it comes to product variations, you can choose between two different ways to apply the general rules and override them from the variation settings.

This can be controlled using the “Enable uploads for products variations” option in the plugin general settings, YITH > Uploads > General:

Variations option

If it is disabled, then, the general rules will not apply to product variations, but you can however enable them from the variation details, as you can see in the following screenshot:

Variations disabled

If it is enabled, then, the general rules will automatically apply to all product variations, but you can disable them from the variation details as shown below:

Variations enabled

If you want to create custom rules for the product variations of one specific product, you can add them through the “Add new rule” button and save the product.

Product rules

Now the general rules will no longer be applicable to product variations, but you can now enable/disable these product rules on every variation.

Variation rules