a)How items are displayed by default in “News items for …” and how you can control it with no change into the core of ZenCart
Sudy case: display New entry in shopping cart page when cart is empty.
copy the following files:
from: /includes/templates/template_default/common/tpl_columnar_display.php
to: /includes/templates/YOUR_TEMPLATES/common/tpl_columnar_display.php
from: /includes/templates/template_default/templates/tpl_modules_whats_new.php
to: /includes/templates/YOUR_TEMPLATES/templates/tpl_modules_whats_new.php
from: /includes/templates/template_default/templates/tpl_shopping_cart_default.php
to: /includes/templates/YOUR_TEMPLATES/templates/tpl_shopping_cart_default.php
Here it is the flow:
Shopping cart display=> tpl_shopping_cart_default.php is loaded
-> in tpl_shopping_cart_default.php, line there is (line #221 may be)
require($template->get_template_dir(‘tpl_modules_whats_new.php’,DIR_WS_TEMPLATE, $current_page_base,’templates’). ‘/tpl_modules_whats_new.php’);
-> here is loaded: tpl_modules_whats_new.php
Keep in mind, this may be the proper place to ad/change something
-> here si loaded tpl_columnar_display.php line # 20
here is used an array variable $list_box_contents.
This array is fiiled with values in: /includes/modues/new_products.php
(you can change here but take care when you upgrade the zen cart)
see line $54 and from 67
(bettre just search for i”while (!$new_products->EOF) {, here is the place!.
-> the statements which basically display your immage products are based on two functions:zen_image and zen_href_link. Both of them are defined in /includes/functions/html_output.php. You can change here but again: take care when you upgrade and be carefully with changing here. They are used in all pages when products are displayed.
Just to point: There is tpl_tabular_display.php which is used by defauult to display list of products in table format. The system is more or less identical.
b)How to change / take godies the payment system
Files used and payment flow
(in includes/templates/YOUR_TEMPLATE/templates or includes/templates/default/templates
-tpl_checkout_payment_default.php
-tpl_checkout_confirmation_default.php
(in includes/clasess)
-payment.php – here are defined payment class
(in root)
-ipn_main_handler.php (for paypall only)
(in includes/modules/payment)
-paypalwpp.php
-eway.php
-moneyorder.php
and more … depends what you have instlled and what you are looking for
for real implementation see sydneywebs.com
Note: ZenCart has one of the best defined paypal gateway implementation.



