PropertiesShow Parent
Tags:   Documentation; FAQ; Problems

You can search the whole VirtueMart Knowledge Base! Just type in your search keywords in the text box on the upper right of this page.

General Information

What is VirtueMart?

VirtueMart is an Open Source E-Commerce solution (a Component or Plug-in) for the Joomla! and Mambo Content Management Systems. It can be run as a Shopping Cart, or in Catalog mode.

You need to install Joomla! or Mambo first (as the "Framework"), and then install & configure VirtueMart.

What exactly is VirtueMart?

VirtueMart is your complete Open Source eCommerce solution. It must be used together with the Content Management System Joomla! (www.joomla.org) or Mambo. Both are released under the GNU Public License, which means by the end, they are free for download and use. Joomla! and VirtueMart are written in PHP and made for easy use in a PHP / MySQL environment.

All you need is to download the latest Joomla distribution from www.joomla.org and the VirtueMart package from this site. Joomla provides the Core System and the Framework, which VirtueMart can use. So you can easily use a complete Shopping Cart Solution within your own dynamic Website ("Portal"), together with many other Plug-Ins, called Components and Modules, like Forums, FAQ, Guestbooks, Galleries........Change the look and feel of your site by using the Templates for Mambo sites, which use CSS and X/HTML......all these Templates and Plug-Ins are available on extensions.joomla.org (mostly for free). Even if you think that you don't need a Portal or a "big" CMS - think about and just try it! You are more flexible with it.

How much does VirtueMart cost?

VirtueMart is free software released under the GNU General Public License.

No limitations exist for VirtueMart. You can create and maintain a site with an unlimited number of categories, products, orders, customers, etc.

Who is behind VirtueMart?

VirtueMart currently has only a very small team. There are 3 to 5 active developers, who help evolve the Core System and update the Project's Open Program Sources. There are a lot of developers and active users on this forum who help pushing this Application forward into the right direction.

Where can I find documentation for VirtueMart?

Mostly in this Wiki. We also have a printable documentation, see Downloads => Documentation here on this site.

Joomla / Mambo and VirtueMart - what's the difference?

Joomla! and Mambo are extensible Content Management Systems that can be further enhanced by installing 3rd party Extensions - e.g. Components (like VirtueMart), Modules and Mambots.

VirtueMart is a Joomla! / Mambo component - It requires either Joomla! or Mambo to be already installed on your Server.

The **Joomla! eCommerce Edition** is a modification of the official distribution of Joomla! with VirtueMart already pre-installed - so you don't have to first install and configure Joomla!, and then install VirtueMart.

I'm totally new to this. Where should I start?

Joomla! is a Content Management System (CMS). It can be installed on your webserver and enables you to manage your whole website online (dynamic website!). If you need more basic information, it is recommended to visit the official website.

After you have informed yourself about the basics, you should download Joomla! and install it on your webserver. On joomlacode.org you can download the latest and older versions of Joomla! and other popular extensions.

The installation process for Joomla! is pretty easy and can be done even by non skilled persons. However - there is a very good documentation available covering all aspects of the system.

If you still have questions or if you are searching for help from the community, you maybe want to join in some discussions in popular forums.

This is the official Joomla! Extensions Directory Site. If you are searching for a forum, a gallery, content modules, flash thingies or such, you should take a look at extensions.joomla.org.

Common Problems

Joomla! 1.0.13 Save/Apply ⇒ Logged Out Problem

Problem: Joomla! 1.0.13 suffers from a serious and annoying bug, which causes the current Admin Session to be closed (Log out) if you save changes to an item. VirtueMart is also affected by this bug when used with Backend Administration.

Solution: To fix the problem, you need to replace two files.

  1. Please make sure that you replace the file
    /includes/joomla.php with this version: joomla.php for Joomla! 1.0.13 (Rev. 8388).
  2. Replace the file
    /administrator/index.php with this version: /administrator/index.php (Rev. 8388).

If you have done this, everything should work as expected. If you have to change the file joomla.php after you've done this patch, make sure you keep the modifications from Rev. 8388!

Image upload problem

Image upload problem, on virtual hosted Joomla! 1.0.13 and VirtueMart 1.0.12.

Prerequisites: If you are running Joomla! 1.0.13 and VirtueMart 1.0.12 you must patch the hotfixes, before proceeding. Also replace the following code to the ps_main.php file. (Thanks digitalcobweb and etilly)

Code for ps_main.php

/* Command to move uploaded file into destination directory */
$temp_file2 = (addslashes(realpath($temp_file)) ==""? $temp_file :  addslashes(realpath($temp_file)));
$d["image_commands"][] = "\$ret = copy(\"".$temp_file2."\", \"".$path.$to_file."\");";


$d["image_commands"][] =
    "\$ret = @move_uploaded_file(\"".addslashes(realpath($temp_file))."\", \"".$path.$to_file."\");

if( \$ret === false ) {
    \$ret = copy(\"".addslashes(realpath($temp_file))."\", \"".$path.$to_file."\");
}";
$d["image_commands"][] = "if( file_exists( realpath(\"$temp_file\") )) {
                                        \$ret = @unlink(\"".addslashes(realpath($temp_file))."\" );
                                  }
                                  else {
                                        \$ret = true;
                                  }";

*/
        /* Return new image file name */
        $d[$field_name] = $to_file;
   return true;
}

Background: Really this is *not* a bug with Joomla! or VirtueMart, it is a Feature of PHP. By default (for Unix/Linux) PHP wants to store any temporary files in the absolute path /tmp. This creates a problem for virtual hosted sites, because we see /tmp as being something like /home/vhost/username/tmp where as PHP sees /tmp as /tmp.

This is the original error I received:

Error code

Warning: getimagesize(): open_basedir restriction in effect. File(/tmp/phptxkDSP) is not within the allowed path(s):
(/.../) in /.../administrator/components/com_virtuemart/classes/ps_main.php on line 70

Warning: getimagesize(/tmp/phptxkDSP): failed to open stream:
Operation not permitted in /.../administrator/components/com_virtuemart/classes/ps_main.php on line 70

Warning: getimagesize(): open_basedir restriction in effect. File(/tmp/phptxkDSP) is not within the allowed path(s):
(/.../) in /.../administrator/components/com_virtuemart/classes/ps_main.php on line 70

Warning: getimagesize(/tmp/phptxkDSP): failed to open stream:
Operation not permitted in /.../administrator/components/com_virtuemart/classes/ps_main.php on line 70
Error: Cannot read uploaded full image temp file: /tmp/phptxkDSP.
One common reason for this that the upload path cannot be accessed
because of the open_basedir settings in the php.ini. Or maybe the
directory for temporary upload files on this server is not readable.

'[See the /tmp/phptxkDSP that is the clue there was something wrong with the path.]'

Problem: The default temporary path for PHP needs to be overridden in the php.ini file.

Solution: Edit the php.ini file by adding the following two lines and replacing your web home directory with the absolute path on your server to your virtual /tmp

Add this to php.ini

session.save_path = /[your web home directory]/tmp
upload_tmp_dir = /[your web home directory]/tmp

Follow-up: Make sure you have or create a tmp directory in your web root.

Conclusion: This works for GoDaddy VirtueMart 1.0.12 with Joomla 1.0.13 hotfix and the ps_main.php fix. I’m not sure if the session.save_path is really needed, but I don’t have time to check.

Module Positions don't work with VirtueMart

For correct functionality of modules appearing on VirtueMart pages you must create a menu link to the VirtueMart component. Without this Joomla has no idea that VirtueMart is being used and can't, for example, change template or assign specific modules on VirtueMart pages.

If you don't want an actual menu link, just create a new menu and publish a link to the VirtueMart component. This will create a new Joomla menu module. Don't publish this module! The link has been published but the menu is not displayed.

REMEMBER - Joomla assigns modules to components, not to component pages. If you assign a module to VirtueMart it will display on all VirtueMart Pages. This is the same for all Joomla components that have multiple pages.

Number of products per row don't change

Products per row and flypage set in the main configuration are the default settings for new categories. They do not alter existing categories.

To alter the number of products per row or the flypages they use, you have to edit the category the products are in.

Product Attributes

Product attributes must be entered as a continuous string with no line breaks.

e.g. Color,red,green,blue;Size,S,M,L

not

Color,red,green,blue;
Size,S,M,L

Failure to do so will not put the second attribute into the cart and you will not be able to update or delete products from the cart.

Advanced Attribute and Discount Prices - TAX

Prices entered for the advanced attributes and discounts should be entered as their value without tax. The reason for this is to allow stores that use multiple tax rates to display the correct values dependent on the shopper

e.g.
shopper from state A sees prices with tax at 8%
shopper from state B sees prices with tax at 10%