MiniVend—the Electronic Shopping Cart

If you need a catalog system for your web page, this product may be just what you are looking for.

Installation couldn't be easier. Simply type

su wwwrun
tar xvzf minivend-latest.tar.gz

in the directory where you want the installation directory to be created. This command will unpack the latest version of MiniVend. The version I downloaded was 3.11, which was released only a week or so before I tried it. (See Resources.)

The user wwwrun owns the web server's /DocumentRoot directory. Any user with write access to both this and the /cgi-bin directory can be used.


The installation process includes a long question-and-answer session, but you can just press enter to answer most of the questions; MiniVend comes with sensible default values. When the installation of MiniVend is finished, you will get the opportunity to install a catalog:

-> /home/httpd/mvend
-> Make the simple demo now? [yes]
Select a short, mnemonic name for the catalog. This will be used to set the defaults for naming the catalog, executable and directory, so you will have to type in this name frequently. If you are doing the demo for the first time, you might use “simple”:
Catalog name? simple
The rest of the installation consists of some simple questions I won't repeat here. The server name and /cgi-bin location should be working before you try to install MiniVend.

Figure 2. The Simple Demo

When everything is installed and ready, you can start the MiniVend server with this command (use the path to your installation):

Installation Notes

MiniVend is a big program, meaning it is very complex, and if you encounter problems, support is not always available. A mailing list is available, but none of my questions got answered during the test period. That included questions about internationalization and the installation problem I had on the one machine on which it was needed.

On the other hand, I found the documentation to be very extensive, though a bit hard to follow at times. The 600KB HTML documentation (see Figure 3) is a definite plus.

Figure 3. MiniVend HTML Documentation

Be very careful with your choice of user for the MiniVend server. This user must have write access to both the /DocumentRoot and the /cgi-bin directory, as you will install a demo with both HTML pages and CGI-scripts. But don't make the mistake of running the MiniVend server and the web server as the same user --that is a security risk to avoid. The best solution in a production system is to create a new user to handle the MiniVend server.

It is the user's duty to ensure the security of sensitive data. You can set up MiniVend to leave the data anywhere on the server or send it by e-mail to the merchant, but you must consider how to encrypt the data. MiniVend supports PGP encryption, so there is a way to set up a secure data transfer.

During this short test period, I obviously didn't have time to test for “wear and tear”, but everything seems to be designed with ease of use in mind. The system tables, e.g., sales tax or freight values, are easy to adjust, and you can update the database off-line or on-line, as individual records or all in one swoop.

Configuration of Web Pages

There's a host of options for configuring web pages. MiniVend has a complete tag language with over 80 different functions. You can embed code in the pages and use conditional statements like [if ...] text [else] else-text [/else][/if], allowing for insertion of text or HTML code based on some computed choice.

All MiniVend commands are embedded in the pages within square brackets ([ ]). MiniVend preprocesses the pages before turning them over to the web server, replacing the commands with the values they represent. The most basic commands are the data tags that embed information from the database in the web page, but there are also commands for looping, inserting text from external files, inserting total fields and a lot more.

Figure 4. Example of a Configured Page

The example in Figure 4 was done with an external file holding all the text of the page. I named a field “webpage” and put it in the database, then inserted this in the template for the product page:

[include pages/products/[item-field webpage]]

which means I want to include a file at this point in the web page. The file should be found in the directory /pages/products/ and have the name that is taken from the web page field of that product.

As a developer, I was happy to learn you can even embed Perl code into the pages. At the same time, I have to agree with the documentation; it is a feature to be used rarely. Embedding Perl is like using a chain saw: you can get the job done quickly, but if used wrong, it can cost you an arm and a leg!



Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Excellent article,Well i

Loneiq's picture

Excellent article,Well i have been working on shopping cart project for the past one week,i found this to be very helpful.
Thank you.

Thanks, it seems some what

Magento's picture

Thanks, it seems some what simple though. I am not sure if it would be good enough for long-term online growth. I think Magento or osCommerce would be a great bet as shopping cart software. But at the end of the day it comes down to users-needs and what they feel comfortable with.


Geek Guide
The DevOps Toolbox

Tools and Technologies for Scale and Reliability
by Linux Journal Editor Bill Childers

Get your free copy today

Sponsored by IBM

8 Signs You're Beyond Cron

Scheduling Crontabs With an Enterprise Scheduler
On Demand
Moderated by Linux Journal Contributor Mike Diehl

Sign up now

Sponsored by Skybot