The plugin Shipment for Virtual Products allows you to ship virtual products (software, music, videos, books) to your customers. It is a custom field product plugin. This tutorial explains how to install and configure the plugin Shipment for Virtual Products.
- Go inthe menu Extensions > Entension Manager, and install the plugin
- Go in the Extensions > Plug-in Manager, and enable the plugin named Virtuemart 2 | product download
Create a custom field
- Go to Components > VirtueMart
- Select the menu Products > Custom Fields
- Click on the button New
- Select for the field Custom Field Type: Plug-ins
- Enter a Title
- Select for the field Cart Attribute the value Yes
- For the field Select a plug-in, select Virtuemart 2 | product download
- Click on Save
Configure your Safe Path
The files to sell are stored in the folder Safe Path given in the VirtueMart configuration.
- Select the menu Configuration > Configuration
- Select the Templates tab
- The parameter Safe Path is the folder where the files to sell are stored. It should be a path outside your web directory.
Upload your files to sell
- In VirtueMart administration, choose the menu Shop > Media Files.
- Click on the button New, to create a new media.
- Set the role to "for Sale". Set the "Image Action" to "Upload" and press save/store.
- Go in VirtueMart administration, choose the menu Shop > Media Files.
- Create a new media. Set the role to "for Sale". Set the "Image Action" to "Upload" and press save/store.
When your files are too big for the http upload, use your ftp client. Upload the files into the directory to your safe path. And then use Synchronise media button in your media view
Attach your media to your product
- Select the menu Products > Products
- Click on the product you would like to add a file to sale
- Select the tab Custom Fields
- In the Custom Field Type area, select the custom field you created to attach a downloadable file
- In the downloadable area, select the file you want to attach to your product
- Check the box Provide as stream, if you want to provide the download as a stream.
- If you provide the download as a stream, change the parameter For the field Maximum speed in kb.
- Click on Save & Close
When your customers should be able to get files which you do connect later to your product, then it is very important that you never delete your custom and that your first product customfield stays the same. Change the used files, just do not delete it, else prior shoppers are not able to access the download anylonger.
Configuration of limits, restrictions and timeframes
- Maximum Downloads means all downloads alltogether
- Maximum downloads per interval in days means how often people are allowed to download your product when you enter a time intervall
- Interval in days is the time in days for the interval
- Maximum number of days for download after the first download is the time how long someone is allowed to download it
- You can set a start or/and a end date for a timeframe
Test your downloadable plugin
On the frontend, select your product, and checkout.
Once the order has been confirmed, your client will receive an order containg a link to downloadable file. He can also download the file via his account using his order number and order password.
The download is created using streaming technics. Be aware that the streaming option does not prevent people using “save target as ...”
Important the download is activated when the order status is set to confirmed/shipped. Downloading the file changes the status of the order item to shipped.
Q: I sell virtual and real products. What shall I do ?
A: For all your virtual products, set the weigth to 0. For the other products, set the weigth to a value different from 0.
Create at least two shipment methods:
- one free of charge with the weigth condition =0. This shipment will be selected when the shopper only buys virtual products
- one or more other shipment methods for weigth different from 0. Those shipment methods will be selected when non virtual products are in the cart.
Q: I want to reenable a download
A: You can do this with the the version 2.0.20, but the core needs a small adjustment (wil be in the core with the next release), just search for administrator\components\com_virtuemart\controllers\plugin.php go to line 49 and replace the word getWord with getString, line 49 should look like this then: $name = JRequest::getString('name','');
Q: I cannot find my media in the dropdown of the pluginA: You did not upload your media as “file for sale”
Q: I get file, which size is too small (1-2 kb).A: Rename the file and add a .html, then open it in a browser, there you can see the error message. Most likely the safe path is not set correctly. Check if your safepath has an ending slash (windows machines a backslash)
Q: How do I set the correct safe path?
Q: The download link does not appear in the email to the client.
A: The download link should be in the email to the client, where the product is listed. Furthermore your client can find the link, checking the order online.
If the link does not appear in the email and/or the order, then this happens almost anytime due a template override of the email or the product details layout. Sometimes people say the link is sometimes there, sometimes not, in this case they have a template providing not correct "add to cart" buttons in the category view.