7.1

Table Of Contents
Implementing a custom store front
By combining the methods described in the previous chapters a custom store front page can be developed. This page resides
outside PrintShop Mail Web and is probably stored on a different domain and can be developed in a scripting language other
than PHP. Implementing a custom store front involves the following subjects:
l Account authentication
l Storefront pages, including redirect information to PrintShop Mail Web
l Redirection from PrintShop Mail Web to your web site/portal at the end of the ordering process
Sample files can be found in the storefront folder located in the webintegration folder of the PrintShop Mail Web Website folder.
Account authentication
The authentication is handled using the external_person_access.php and is similar to the External person access process as
described in the previous chapter. A change is made to the process_login.php file where a custom storefront file (store-
front.php) is included when the authentication was successful.
<!-- Process_login.php snippet-->
<?php
if ($cReturn != "0") {
//Success
$_SESSION[fcUserName]= $_REQUEST[fcUserName];
$_SESSION[fcPassword]= urlencode($cReturn);
include_once("storefront.php");
} else {
//Failed
$fcUserName = $_REQUEST[fcUserName];
$cReturn = false;
include_once("index.php");
}
?>
Custom store front pages
In our example the storefront.php contains a hard coded list of documents. The images on the page have a hyperlink pointing
to the external_login.php file.
©2010 Objectif Lune Inc - 205 -