For users of the fantastic “Ecommerce Templates” PHP shopping cart software, here is a FREE download file containing HTML and PHP code snippets to generate dynamic <title>, <meta description> and <meta og: tags> in your website page code.
Developed here at IT ZAP Website Design Works, this dynamic code is essential to maximise your Search Engine Optimization strategy and Social Media impact.
free, no charge, gratis
This file will UnZip into a folder named “ect-dynamic-code”
Once you have downloaded and UnZipped the file, please open the “00-ect-dynamic-code-readme.pdf” file which explains all.
The HTML and PHP code is provided “as is” and was written using Adobe Dreamweaver CC 2015.
UPDATED Monday, 29th January 2018.
I have been testing this code for some time now on this website, and others, using a succession of Ecommerce PHP Versions 6.6 up to the very latest release. My standard website configuration is as follows:
No custom Mods installed.
cPanel LiteSpeed Server running PHP Version 7.1.6
Vanilla page URL’s. (No .htaccess Mod RewriteRules)
Both “Short” and “Long” descriptions entered for each Category and Product page. (Short description is a “must have” for the <meta description> entry.)
The dynamic code will work using Search Engine Friendly URL’s, BUT with a couple of modifications that are explained in the ReadMe pdf.
Implementing this dynamic code requires the end user to open the sample files provided, then Copy (CTRL+C) and Paste (CTRL+V) code snippets into your own Ecommerce Templates website PHP files in 3 locations:
Above <!DOCTYPE html>
Inside “Editable Regions” in the <head>, and
Inside “Editable Regions” in the <body> of your page.
The code must go inside "Editable Regions" so as it is not overwritten upon Template update.
Even if you are not on Facebook or Twitter, do add all the <meta og: tag> code entries just the same, because somebody may well “Share” your page URL on a Social Media website, which can then load up all that “Open Graph” information automatic.
WinZip Download File Contents
Here is a description. See the ReadMe pdf for more detail and critical notes.
vsadmin\includes.php : Special Parameters used in the PHP code that you need to EDIT and then add to your existing includes.php config file.
start-ect-metainfo-page.php : Use of this “include_once” file is optional, but my recommended way to load the Ecommerce Templates content management system files first up at Line 1, all in the correct order, above <!DOCTYPE html>
Important: If you have any of those Ecommerce Templates system files being loaded further down on any page, then you must remove those lines. They cannot be duplicated. And without “metainfo.php” loaded up top, the dynamic code entries will be BLANK.
start-ect-page.php : Another optional “include_once” file, but without loading metainfo.php on the end. Loaded first up on ECT pages like index.php, clientlogin.php, cart.php, search.php, etc, where page title and description code is entered manually.
social-meta-ids.php : An “include_once” file that I use to insert Facebook “Administrator” and “Application” ID numbers. You need to EDIT and insert your own unique Facebook ID numbers. You can also add <meta> properties for Twitter in here as well.
(a) To create a Facebook App ID
for your website, go to the Facebook Developer page here
, click on "Get Started" at top-right of the page and then enter your website details. The App tracks and properly attributes all the Likes, Shares, Reactions, Comment numbers to your Business Page. It also generates detailed Facebook Insight Reports
that will provide helpful data in measuring your Facebook Post reach, effectiveness, marketing and planning advertising campaigns.
(b) To obtain your correct Facebook Administrator ID
number, go to the Find My Facebook ID website here
and enter the URL of your Personal
Facebook Page. Note that you can add Multiple Facebook Administrator ID lines, so as each authorised person will get access to view those detailed Facebook Insights reports.
categories-code.php : Use this to copy/paste dynamic code snippets into your categories.php file.
products-code.php : Use this to copy/paste dynamic code snippets into your products.php file.
00-static-category.php : This is basically a CLONE of your products.php file for use when creating a static “Category URL (Optional)” page in 30 seconds flat, where the “Category Function” is “Products can be added to this category”.
00-static-top-category.php : This is basically a CLONE of your categories.php file for use when creating a static “Category URL (Optional)” page in 30 seconds flat, where the “Category Function” is “Categories can be added to this category”.
manufacturers-code.php : Use this to copy/paste dynamic code snippets into your manufacturers.php file. It is simply a CLONE of categories.php, but uses those parameters you entered into includes.php named : $rootmanufacturertitle and $rootmanufacturerdescription
proddetail-code.php : Use this to copy/paste dynamic code snippets into your proddetail.php file. The line <?php print $metaogimage; ?> does require Ecommerce Plus PHP Version 6.6
00-static-proddetail.php : This is a CLONE of proddetail.php that you can use to create a “Has Static URL” product page in 30 seconds flat.
Once you have Pasted the dynamic code into your Ecommerce Templates PHP files, delete all the spaces between lines. They were only put there to separate code snippets for clarity.
Hopefully the explanations provided are clear enough. Feedback is welcome, along with any suggested improvements.
Do you have dynamic code for the ASP and Wordpress versions ?
No, sorry. I do not work with those versions. This is a conversion that somebody else in the Ecommerce Templates community might kindly provide.
Can you do it all for me ?
Yes, if you are a PHP user and are happy to pay a modest fee (in AUD$) for the time involved, then you may order below. I would need a copy of these files:
Dynamic code implemented by IT ZAP is guaranteed to work with Ecommerce Templates Shopping Cart PHP Plus Versions 6.6 onward.