
XAO::Commerce - eCommerce Suite

See sample site templates, images and usage examples.

XAO::Commerce is a part of XAO open source web services suite. It allows to build eCommerce sites using XAO::Web (see XAO::Web for details).
XAO::Commerce consists of a number of templates and the following objects:

The easiest way to install XAO Commerce is to use CPAN. Usually you would need to something like this:
sudo perl -MCPAN -e'install XAO::DO::Commerce'
If you downloaded archive and want to install it manually then usual four commands will do:
perl Makefile.PL make make test sudo make install
Once installed the XAO Commerce is ready to be used and its templates are located in the XAO installation path (usually /usr/local/xao/projects) under templates/.
Here are the steps you need to follow to get a simple working sample eCommerce site that uses XAO Commerce:
The distribution comes with a sample site in the directory sample/. This directory contains a set of templates, configurations, objects and tools for putting together a functioning sample eCommerce website. To set up this sample website:
Install the required packages, XAO::FS, XAO::Web and XAO::Catalog, along with their requirements.
% mysqladmin create commerce
% xao-fs --dsn=OS:MySQL_DBI:commerce init
cd /usr/local/xao/projects/commerce perl ./configure.pl
Enter OS:MySQL_DBI:commerce as the database DSN and username/password of a user that has full access to that database.
./bin/build-structure
./bin/add-admin LOGNAME PASSWORD EMAIL REAL_NAME
% bin/scan-flatfile sample_products.txt > sample_products.xml % bin/ifilter-flatfile sample_products.xml % bin/import-map FlatFile % bin/mark-empty-categories yes
NOTE: see README in `sample' for details.
<VirtualHost SOME_HOST_NAME>
ServerName SOME_HOST_NAME
CustomLog /usr/local/xao/projects/SITENAME/logs/access_log combined
ErrorLog /usr/local/xao/projects/SITENAME/logs/error_log
DocumentRoot /usr/local/xao/projects/SITENAME/images
<Directory /usr/local/xao/handlers>
Options ExecCGI
# to use cgi's
SetHandler cgi-script
# to use mod_perl:
#SetHandler perl-script
#PerlHandler Apache::Registry
</Directory>
RewriteEngine on
RewriteRule ^/images/(.*)$ \
/usr/local/xao/projects/SITENAME/images/$1 \
[L]
RewriteRule ^/(.*)$ \
/usr/local/xao/handlers/xao-apache.pl/SITENAME/$1 \
[L]
</VirtualHost>
Here you replace SOME_HOST_NAME with a something that you have in your DNS or at least in /etc/hosts file and SITENAME with the name you give your site. It is assumed in this example that the xao installation path used is /usr/local/xao/ -- you need to change it if you used a different path.

No publicly available methods.

Nothing.

Copyright (c) 2002 XAO Inc.
Marcos Alves <alves@xao.com>.

Recommended reading: XAO::Web, XAO::DO::Web::Page.