Prev | Current Page 481 | Next

Emilian Balanescu and Cristian Darie

"Beginning PHP and MySQL E-Commerce: From Novice to Professional, Second Edition"

const.PAYPAL_EMAIL}" />

value="{$obj->mPayPalContinueShoppingLink}" />
value="{$smarty.const.PAYPAL_RETURN_URL}" />
value="{$smarty.const.PAYPAL_CANCEL_RETURN_URL}" />



2. In the same file, add a reference to the cart summary component:
{include file="search_box.tpl"}
{include file="departments_list.tpl"}
{include file=$obj->mCategoriesCell}
{include file=$obj->mCartSummaryCell}
3. Open presentation/store_front.php, and update it as highlighted in the following code snippet. This
way, the StoreFront class will recognize the CartAction query string parameter.
class StoreFront
{
public $mSiteUrl;
// Define the template file for the page contents
public $mContentsCell = 'first_page_contents.tpl';
// Define the template file for the categories cell
public $mCategoriesCell = 'blank.tpl';
// Define the template file for the cart summary cell
public $mCartSummaryCell = 'blank.tpl';
// Page title
public $mPageTitle;
...
public function init()
{
...
// Load product details page if visiting a product
CHAPTER 12 ?–  CREATING YOUR OWN SHOPPING CART 382
if (isset ($_GET['ProductId']))
$this->mContentsCell = 'product.


Pages:
469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493