Sage Line 50 eCommerce Integration

The brief...

We run a high street shop, we use Sage Line 50 for point of sale linked to our till, we need our website to automatically update with our current stock levels and any new products as and when they come in.


There are two parts to this system. The first is a Windows .exe which runs on a PC alongside Sage, this software from Internetware is called "Connect". Connect runs via a scheduling system, it interogates the Sage database and uploads any changes to the web server via a data stream formatted in XML. We wrote the 2nd part of the system, it's a program written in PHP which runs on the web-server. It takes the XML data, processes it and updates the website. This is a small snippet of the data it processes:-

XLM formatted data from the Sage system


This image appears until the new one is uploadedImages are also embedded in this data using base_64 encoding. But to save on bandwidth the images are updated just once a day at around 3pm. When new products are added a temporary image containing the text "Sorry, but we don't yet have an image..." will appear in place of the product image. The website's database contains product data, price and stock level, this is all displayed as people browse the various products that are available. Products are grouped into categories and the system will create new ones if required.


This is a snippet of the code that drives the system, it runs on the web-server...

Php Code snippet


The Refresh Computers website is based on the osCommerce system, a popular open-source e-commerce package written in PHP which powers thousands of websites around the world. Normally with this system products are added via the administration section of the site. With this new system all of that is driven by the Sage system. Orders placed via the website are also brought down into Sage.



A product listing eCommerce website with continuously updated stock level and pricing updates driven by Sage.



t: 023 9259 5694    3 Rose Hill, Lovedean, Waterlooville, Hampshire, PO8 9QU

Happy green bug