|
|
|
BROWSE
All Titles WordPress Web Services SOA BPEL Web Graphics & Video Web Development RAW Portugues, Espanol, Italiano, French PHP/MySQL Oracle Open Source Networking & Telephony Moodle Microsoft & .NET Linux Servers jQuery Joomla! JBoss Java e-Learning e-Commerce Dynamics Drupal CRM Cookbook Content Management Beginner Guides Architecture and Analysis AJAX Future Titles Recently Published Titles |
Integrating Zen Cart with Content Management Systems
There are various types of Content Management Systems (CMS) which are widely used for building and managing a website. Although Zen Cart is very good for running an online shop, it cannot be used for building a company website. Your organization may have a website running a CMS, and as you are going to open an online shop, you may need to integrate Zen Cart with that existing CMS. In this article by Suhreed Sarkar, we will see how we can integrate Zen Cart with some of the existing Content Management Systems How to Integrate with CMS?While attempting integration of one CMS with another, some simple principles should be remembered. For all integration attempts, you have to consider the following aspects:
Now, we will see how to integrate Zen Cart with other CMSs. You will notice that at least one of the above-mentioned aspects is present in such integrations. Joomla!/MamboIf you are using Joomla!/Mambo and want e-commerce functionality, you have a number of choices. Among these, the best one is using the VirtueMart component. The VirtueMart component for Joomla!/Mambo is quite similar to Zen Cart or osCommerce. Only a few features of Zen Cart or osCommerce are missing in VirtueMart. However, if you still want to integrate Zen Cart into the existing Joomla!/Mambo website, you have two options-and neither is easier than the other: Use Zen Cart as a wrapper or, develop a component based on Zen Cart. Using Zen Cart as a wrapper is in its true sense not an integration. It runs separately and Joomla! provides a menu link. Clicking on this link will show Zen Cart in a wrapper window. If you are experienced with Joomla! or Mambo, you can figure out how a menu item can be added to show the application in a wrapper. However, adding a wrapper may appear to be an integration if you modify the Zen Cart template accordingly. As the Zen Cart shop appears in the wrapper, it would be wise not to use headers and sidebars in the Zen Cart template. Links to the categories and other menus can be provided in the headers. A separate login mechanism should also be provided in the Zen Cart template. Developing a bridge for Zen Cart and Joomla! is a hot topic in the Zen Cart forum. Users of both Joomla! and Zen Cart agree that integration or bridging of these two will be of great value. However, due to the framework of these two systems, developing such a bridge has some complexities and takes some time. Recently, a discussion on this topic has led to the development of such a bridge by the open-source enthusiasts. Please watch the following thread:http://tinyurl.com/65ypyu. Another possibility is JFusion plug-in for Joomla! (available at www.jfusion.org) which is a framework for integrating several forums to Joomla!. The developer of JFusion has proposed developing such a plug-in for Zen Cart as well. It is hoped that JFusion will be able to integrate Zen Cart to Joomla! soon. DrupalDrupal is a powerful CMS and is widely used. There are a wide range of modules available for Drupal and it is used for different types of websites. There are a great number of Drupal users who want to integrate Drupal and Zen Cart-as both are considered useful in their category. Until recently, there was no easy way to integrate Drupal and Zen Cart. Very recently, Zen Cart Integration module has been released as a development version. For now, it works on Drupal 5.x and Zen Cart 1.3.7. Once this module is installed and configured, you can create Zen Cart categories and products from Drupal. As other nodes, these products and categories will be displayed as nodes in Drupal. When visitors click on these products they see product details as a Drupal node, but when the product is added to cart, it redirects to the Zen Cart shop. This module also provides a single sign-on facility. For integrating Zen Cart into Drupal, download the module from http://drupal.org/project/zencart. Before we proceed with the integration of Drupal and Zen Cart, assume that you have installed Drupal and Zen Cart on the same server. Let us suppose, Drupal is installed in e:wwwdrupal57 directory and Zen Cart 1.3.7 is in e:wwwzc directory, and these two uses separate database on the same MySQL server. Follow these steps:
![]() The Zencart Integration screen has the following sections: Once you have configured these options, click the Save configuration button, or revert to defaults by clicking the Reset to defaults button. ![]() Similarly you can test single sign-on features by signing in to either Drupal or Zen Cart and trying to purchase items from these two shops. This article has been extracted from: Zen Cart: E-commerce Application Development
Gallery2Gallery2 is a web-based software product that lets you manage photos on your own website. It creates a catalog of photos which visitors can view as thumbnails as well as in its original size. It has an intuitive interface to create and maintain albums. It can create thumbnails automatically and can be used for image resizing, rotation, ordering, captioning, searching, and some other functions. You can use Gallery2 to build a community site for sharing photos. You can create the community using Gallery2 and registered users can share their photographs by uploading their own photos. You need to integrate Gallery2 with Zen Cart if you want to sell photos from your photo gallery. Gallery2 has a great mechanism to integrate with Zen Cart. The Gallery2/Zen Cart integration module is available at the Gallery2 download site http://dakanji.com/g2stuff/zcg2-3_2_1a-full.zip. Using it, users can organize their photos and other multimedia files into Gallery2, and offer them for sale through Zen Cart. In integrating Gallery2 with Zen Cart, you have to configure Zen Cart first. Follow these steps for Zen Cart:
Remember that for Gallery2/Zen Cart integration, both Zen Cart and Gallery2 data tables need to be in one database. In Gallery2, you need to make the following changes:
![]() ![]() ![]() ![]() ![]() If you do not want to sell an item, you will need to disable that item in Zen Cart as the module adds all data items in your gallery to Zen Cart. You can add photograph items from Gallery2. Adding any item to the Gallery2 album will simply show that item in Zen Cart. You can add product options from Gallery2 by clicking on the Zen Cart link in your Gallery2 site administration menu. When you have installed the Gallery2/Zen Cart bridge, you will find a product type in Zen cart named Product-Gallery. All the items from Gallery2 need to be of this type. If you edit any item from Zen Cart and change the product type of any Gallery2 item, the link with the Gallery2 will be broken. Also, note that the Gallery2 bridge will co-exist with Zen Cart image handler and lightbox add-on for Zen Cart. These will handle product images for Zen Cart, whereas Gallery2 add-on only handles images added in Gallery2. You cannot assign the Main category in Zen Cart as the root product category for Gallery2. The category you are selecting in the Gallery2 bridge configuration must be a sub-category product. Once the configurations are done, you can see the photographs from Zen Cart. Visitors can also order photographs from Zen Cart. While you are in Gallery2, you can also place an order by clicking the add to cart link, which is redirected to Zen Cart. WordPressWordPress is an extremely powerful and widely used open-source blogging platform. It has a wide community of developers and users, and almost all kinds of plugins are available for it. Although there are some shopping cart plugins for WordPress, they are not full-blown shopping carts like Zen Cart or osCommerce. E-commerce plug-ins available for WordPress have limited features. Those who are running blogs using WordPress may want to integrate it with Zen Cart to provide e-commerce functionality to their blogs. In fact, there is a Zen Cart module for integrating these two. You can download that module from www.zen-cart.com. After downloading the plug-in WordPress on Zen Cart, you have to install it on the webserver. You can install the plug-in in two ways: first, in an environment where you have a working WordPress installation, and second, when you have not installed WordPress. WordPress and Zen Cart Installed in Separate DirectoriesWhen you have an existing installation of WordPress, generally it will be in a separate directory from that of the Zen Cart installation. If your web document root directory is public_html, then the installation directories may be: /public_html/blog and /public_html/shop. Follow these procedures to install WordPress on Zen Cart plug-in: Step1: Install WordPressIf you have not installed WordPress yet, then download the WordPress files from www.wordpress.org and unzip the files. Then, upload the files to your webserver's /public_html/blog directory. Now, change the permission of this directory to 777 and point your browser to http://yourdomain.com/blog/wp-admin/setup-config.php. The installation wizard for WordPress will be displayed. Follow the instructions on the wizard and give the necessary information. Once all of the information is given, WordPress will be installed. Step 2: Configure WordPressDuring installation, an administrative account will be created. Note the username and password for this account. Then, point your browser to http://yourdomain.com/blog/wp-admin/. The login page will be displayed. Type the username and password for the administrative account and click on the Login button. You will see the dashboard for administering WordPress. Go to Options | General. Now, change the Blog Address (URL) to Zen Cart's URL http://yourdomain.com/shop/. From the administration dashboard, go to Presentation | Themes and select WordPress Default 1.6. Step 3: Upload WordPress on Zen CartWhen you unzip the WordPress on Zen Cart plug-in zip file, you will find that there is a directory called ZC_ROOT and WP_ROOT. Now, upload the contents of ZC_ROOT directory to Zen Cart's installation path on the server, that is, /public_html/shop/. Similarly, upload the contents of the WP_ROOT directory to WordPress' installation path, that is, /public_html/blog. Before uploading the contents of the ZC_ROOT directory, please change the name of the /ZC_ROOT/includes/templates/MY_TEMP/ directory to that of the template directory you are using for your Zen Cart shop Step 4: Edit WordPress FileFor older versions of WordPress, you may need to edit the /wp-include/template-loader.php file. Open the file in a text editor and replace all exit; with return;. However, you may not need this for the newer versions of WordPress. WordPress 2.3.1 can work without this modification. First, try without this modification. Step 5: Edit Zen Cart FileYou also need to edit another file in the Zen Cart installation. Open the /includes/extra_configures/wordpress-config.php file under the Zen Cart installation folder and find the following line: define ('ABSPATH','/var/www/vhost/example.com/public_html/blog/'); Type the appropriate WordPress path, that is, /home/username/public_html/blog/. The above line will look like this: define ('ABSPATH','/home/suhreed/public_html/blog/'); If you are trying it on Windows, you may need to put the absolute path, as in, e:/www/blog. Step 6: Configure Sideboxes from Layout Boxes ControllerOnce the file modifications have been done, login to the Zen Cart administration panel. Go to Tools | Layout Boxes Controller. The screen will notify you that some new sideboxes-wp_cats.php, wp_archives.php, wp_pages.php, wp_links.php, and wp_sidebar.php-have been found. To use these sidebars, click on the reset button at the bottom. To show these sideboxes on your Zen Cart shop, click on the sidebar and change its left/right column status. This article has been extracted from: Zen Cart: E-commerce Application Development
Step 7: Test your IntegrationNow, it's your time to see how the Zen Cart and WordPress integration works. Point your browser to your Zen Cart shop, that is, http://yourdomain.com/shop/. If everything is okay, you will find the screen as shown in the following screenshot: ![]() If the ABSPATH value in wordpress-config.php file is not entered appropriately, you will get a message saying that wp-config.php file in a particular path is not found. In that case, edit the wordpress-config.php file and enter the correct path to the WordPress installation. Note that a left sidebox named Blog Sidebar is shown in your Zen Cart shop. You will find links to pages in the blog, links to archives, and links to categories. Click on a link and that category, archive or page will be displayed. You may be disappointed when you look at the result because the whole WordPress page with headers, footers, and sidebars is displayed. If you have some knowledge of customizing WordPress themes, you can work out a nice solution by removing the header, the footer, and the sidebar from the theme layout. For learning WordPress theming, check the excellent tutorials at www.wordpress.org. You can also read WordPress Themes, published by Packt. ![]() WordPress and Zen Cart Installed in the Same DirectoryYou can also install WordPress and Zen Cart in the same directory. In such a case, install Zen Cart first. Configure it for normal use, and then proceed with the installation of WordPress. For example, if your Zen Cart installation is in /public_html/shop/, then WordPress will also be installed at /public_html/shop/. First, download the WordPress installation package, unzip it, and upload all files, except index.php. After uploading the files to the Zen Cart directory, i.e. /public_html/blog/, change the access permission of these to 777. Now, point your browser to http://yourdomain.com/shop/wp-admin/setup-config.php. The installation wizard for WordPress will be displayed. Follow the instructions of the wizard and provide the necessary information. Once all information is made available, WordPress will be installed. Now, follow Steps 2 to 7 as described in the previous section. In this case, the paths to Zen Cart and WordPress will be same. When you use other themes, it is necessary to revise the header of the WordPress theme, a footer, a sidebar, and a style sheet. XOOPSXOOPS is a CMS written in PHP. It uses a modular architecture allowing users to customize, update, and theme their websites. XOOPS is an acronym of eXtensible Object Oriented Portal System. It aims to serve as a web framework for use by small, medium, and large sites through the installation of modules. For example, a small XOOPS installation can be used as a personal weblog or journal, but this can be expanded upon and customized. For example, users might add the appropriate modules (freeware and commercial) to store content in news, forums, downloads, and more. If you have a XOOPS-based website and want to add e-commerce functionality to that website, you can use Zen Cart with XOOPS. There is a Zen Cart XOOPS Integration module which can be used to integrate Zen Cart with XOOPS. After downloading the module, upload the files to your XOOPS installation directory. Then, install it as a normal module for XOOPS. Ensure that the Use custom session value in Preferences | System | General Settings is on. You need to change the permissions of some files and folders. CHMOD the following folders to 777:
The default admin URL for the Zen Cart shop will be shop/admin with username and password admin. XOOPS Zen Cart has a built-in Zen Cart installation. Zen Cart files are included with this module and are installed as a module of XOOPS. This module has the following features:
e107e017 is a comparatively new CMS with lots of features, and ease of use. It has hundreds of plug-ins through which you can extend its capability. You will find a plug-in to bridge with Zen Cart too. Bridging through this plug-in is easier for the layperson. This plug-in is available at: http://plugins.e107.org/e107_plugins/psilo/psilo.php?artifact.178. Download it, unzip it and copy the zencart_bridge folder in your e107 installations e107_plugins folder. Then, install the plug-in from the administration panel's Plugins | Plugin Manager. You will see the list of installed and available plug-ins. Click on the Install button beside the ZenCart Bridge plug-in. It will be installed without any prompt. ![]() Once the Zen Cart bridge is installed, you will see the list of installed plug-ins in the main administration panel. You can also access configuration options by selecting Plugins | ZenCart Bridge. You have to configure the following options:
The main configuration for bridging e107 and Zen Cart is configuring the database options. However, it is also automated, and can be used easily. You can configure the Zen Cart database connection from Plugins | ZenCart Bridge | ZenCart Connection. ![]() The following are the options for the database configuration:
The Zen Cart Bridge works well with e107. However, it acts only as bridge. Using e107, users can also login and purchase products from the Zen Cart shop. This kind of bridge is good when you have kept the shop as a linked site with the e107 site. For better performance, it is suggested that you use the same database both for Zen Cart and e107. But, don't forget to use the zen_ prefix for the Zen Cart tables. phpBBphpBB is a bulletin board service for creating communities of common interest. This is widely used on the Internet, and I hope you have seen one or two by this time. You can integrate a phpBB bulletin board service with a Zen Cart shop. This can be done while you are installing Zen Cart. If you want the forum or bulletin board service, download and install phpBB. You can download phpBB2 or phpBB3 from www.phpbb.com/downloads/. Install phpBB on the same server. Then, start installing Zen Cart. There will be a step asking you whether you want to integrate phpBB or not. Choose Yes in this screen, and then specify the phpBB directory path. This way, phpBB will be integrated to Zen Cart during installation. If you do not integrate phpBB during the Zen Cart installation, you can do it at a later stage. Whenever you think that you need to add a forum to your shop, just install the phpBB forum and follow these instructions to integrate it with the Zen Cart shop.
![]() Integration with phpBB means, when a user registers with Zen Cart, the same account is created on the phpBB. While creating an account on Zen Cart, the user is prompted to choose a nickname for the phpBB forum. Users can also see a link to the phpBB in the Information sidebox. Clicking on this link will take you to the phpBB forum where a user can login using his or her nickname and password. SummaryIn this article, we have learned about the integration of Zen Cart with other CMSs. We have discussed the necessity of integration, characteristics of successful integration, and ways to integrate CMS. Then, we have seen ways to integrate Zen Cart with other CMSs such as Drupal, WordPress, Gallery2, e107, and phpBB. Bridge or connectors are used for such integration. The development of such bridges or connectors for other CMSs such as Joomla! are under consideration. Keep an eye on those community forums for solutions. This article has been extracted from: Zen Cart: E-commerce Application Development
About the AuthorSuhreed Sarkar—IT consultant, trainer, and technical writer—studied Marine Engineering, served on board a ship for two years, then switched to the computer world with MCSE in Windows NT 4.0 track late in 2000. His latest field of study is business management and he has earned an MBA from the University of Dhaka. He has a bunch of BrainBench certifications including PHP4, Project Management, RDBMS Concepts, E-Commerce, Web Server Administration, Internet Security, Training Development, Delivery and Evaluation, and Technical Writing. As a trainer, he has taught courses on web design, development, and e-commerce. He also delivers lectures on MIS and e-business in public and private universities in Bangladesh. Being passionate about learning and teaching new skills, he prefers hacking and teaching to actual coding for clients. As a consultant and trainer he has experience consulting for some international organizations including the United Nations, where he helped clients building and adopting their enterprise portals, large scale databases, and management information systems. He is the best-selling technical author in Bengali—having a dozen books published on topics covering web development, LAMP, networking, and system administration. As an open-source enthusiast, he is active in different forums and takes every chance to promote open-source CMSs and shopping carts including Joomla, Mambo, Moodle, WordPress, osCommerce, Zen Cart, etc. While not busy with hacking some apps, blogging on his blog (blog.suhreedsarkar.com), reading the philosophy of Bertrand Russell or the management thought of Peter F Drucker—he likes to spend some special moments with his family—wife, son, and daughter. Suhreed lives in Dhaka, Bangladesh with his family. Books from Packt | Want to know more about Packt's Article Network? Interested in contributing your article ideas? Please visit our FAQ for more information. See More |
| ||||||||