MetaMadeSimple - Meta Tags As Simple as 1,2,3

Introduction:

As we all know CMS Made Simple is powerful, robustic and still is simple in use, and so are the most of the modules. There are some useful modules regarding SEO and Meta Tags Generation, which are quite helpful and have thier own Graphical User Interface for user interaction. MetaMadeSimple is another addition to that already helpful community but it is being distributed in a different way while keeping simplicity in mind.

Though other modules were doing their job, but after some time they become obsolete and needs continuous updation along with CMS Made Simple Core releases and PHP, Smarty upgradation. Updating modules is not only a continous work but sometimes there comes compatibility issues (which are though solved later).

MetaMadeSimple is a STATIC File, which doesn't need any database operation, permissions or installation etc. I've combined almost all of the useful Meta Tags in one file for easy global usage. MetaMadeSimple is Compatible with all versions of CMS Made Simple either 1.x or 2.x series.

You don't need to install other modules for SEO/Meta Tags generation, just follow the below guide and you are 100% good to go.

STEP ONE - First Thing First

  • First of All you need a logo for your website (you can even use a simple text based image for that purpose, if you don't have a logo. (.PNG) format is recommended.
  • Make some variations (width-height wise) for that logo. Those variations will be used later. Lets' say your default logo width is 200 pixel. Resize that same logo in various sizes like 152px, 120px, 76px, 60px. When you use aspect ratio option in Photoshop or MS Paint, height will be adjusted automatically.
  • Now create a folder named "icons" in your theme_path for example ({root_url}/uploads/images/icons/) and save all those variations in PNG format in that icons folder. Rename those files for easy access, for example. logoname-200x180.png, logoname-152x136.png, logoname-60x54.png etc.
  • Generate a Favicon for your logo from http://tools.dynamicdrive.com/favicon/ and save that as favicon.ico in above created icons folder.

STEP TWO - Re-Format the Template

Copy/Paste following in your Template(s) - Yellow colored comments are explanation.

Copy below data in HEAD SECTION of your Template(s)

Same Code without Comments

{strip}
{process_pagedata}
{cms_lang_info assign="nls"}
{$theme_path = "{uploads_url}/"}             <== you can write your sub-folder name if you are using {root_url}/uploads/your-sub-folder structure.
{title assign="main_title"}                          <==That will help to use Page_Title in News, Blogs etc
{content assign="main_content"}              <==That will help to use Page contents to use in other modules
{assign var='author' value=''}                     <== In value type Website Owner Name
{assign var='copyright' value=''}                 <== In value type Year - Company Name
{assign var='publisher' value=''}                 <== In value type Publisher/Company/Owner Name
{assign var='developer' value=''}                 <== In value type Web Developer/Administrator Name
{assign var='city' value=''}                            <== In value type city name
{assign var='country' value=''}                        <== In value type country name
{assign var='address' value=''}                    <== In value type full address
{assign var='email' value=''} <== in value type email address, usually it would be info@yourwebsite.com
{cms_selflink dir="previous" assign="prev_page"}
{cms_selflink dir="next" assign="next_page"}
{share_data scope=parent vars="nls,theme_path,main_title,main_content,prev_page,next_page,author,copyright,publisher,developer,city,country,address,email" scope=global}
AS We have declared global variables above, we can use them anywhere in website (contents, news, blogs, products, lists etc) by calling them via {$variablename} i.e. {$author}  etc.
{/strip}<!DOCTYPE html> <== Don't press enter after {/strip} tag, as if you do, you will have unwanted blank row in your page code.
<!--[if IE 8]><html lang="{$nls->htmlarea()}" dir="{$nls->direction()}" class="lt-ie9" prefix="og: http://ogp.me/ns#" itemscope itemtype="http://schema.org/LocalBusiness"> <![endif]-->
<!--[if gt IE 8]><!--> <html lang="{$nls->htmlarea()}" dir="{$nls->direction()}" prefix="og: http://ogp.me/ns#" itemscope itemtype="http://schema.org/LocalBusiness" > <!--<![endif]-->
<head>
<meta charset="{$nls->encoding()}" />
<title>{$main_title nocache} - {sitename}</title>
<meta name="HandheldFriendly" content="True" />
<meta name="MobileOptimized" content="320" />
<meta name="viewport" content="initial-scale = 1.0, maximum-scale = 1.0, user-scalable = no, width = device-width">
<meta http-equiv="cleartype" content="on" />
<meta name="msapplication-TileImage" content="{$theme_path}/images/icons/logoname-152x122.png" />
<meta name="msapplication-TileColor" content="#5C5A59" />
{metadata}
{if isset($canonical)}<link rel="canonical" href="{$canonical}" />{elseif isset($content_obj)}<link rel="canonical" href="{$content_obj->GetURL()}" />{/if}
<!--[if lt IE 9]><script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<script src="//css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js"></script><![endif]-->

You can Use {cms_stylesheet} tag, if you are attaching stylesheets from CMS itself, otherwise you can simply upload your stylesheets and javascript files in your uploads directory and call them as below
<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,400,300,600">
<link rel="stylesheet" href="{$theme_path}/style.css" media="all">
<!--[if lte IE 7]><link rel="stylesheet" href="{$theme_path}/style.ie7.css" media="screen" /><![endif]-->

<script src="{$theme_path}/jquery.js"></script>
<script src="{$theme_path}/script.js"></script>


Now we will use different variations of logo, that we made earlier.
<link rel="apple-touch-icon-precomposed" sizes="152x122" href="{$theme_path}/images/icons/logoname-152x122.png" />
<link rel="apple-touch-icon-precomposed" sizes="120x96" href="{$theme_path}/images/icons/logoname-120x96.png" />
<link rel="apple-touch-icon-precomposed" sizes="72x58" href="{$theme_path}/images/icons/logoname-72x58.png" />
<link rel="apple-touch-icon-precomposed" sizes="60x48" href="{$theme_path}/images/icons/logoname-60x48.png" />
<link rel="shortcut icon" sizes="196x157" href="{$theme_path}/images/icons/logoname-196x157.png" />
<link rel="shortcut icon" href="{$theme_path}/images/icons/logoname-60x48.png" />
<link rel="icon" href="{$theme_path}/images/icons/favicon.ico" type="image/x-icon" />
{cms_selflink dir="start" rellink="1"}
{cms_selflink dir="prev" rellink="1"}
{{cms_selflink dir="next" rellink="1"}

Copy below Data Before </body> tag in your Template(s)

{capture}{content block='SEO_Keywords' wysiwyg='false' assign="SEO_Keywords"}{/capture}
{capture}{content block='Page_Description' wysiwyg='false' asign="Page_Description"}{/capture}

STEP ONE Explanation STEP TWO Explanation STEP THREE Explanation


Go to TOP STEP TWO Code STEP THREE Code

STEP THREE - Global Settings ==>> Global MetaData Section

Copy/Paste following in Global Settings  -> Global MetaData Section - Yellow colored comments are explanations,  Replace all bold values with your Own data.

Same Code without Comments

<meta name="robots" content="index, follow" />
<meta name="title" content="{$main_title nocache}" />
<meta name='keywords' content="{content block='SEO_Keywords' wysiwyg='false'}"> <== keywords, that you define, while creating a page will show here.
<meta name='keypharases' content="{content block='SEO_Keywords' wysiwyg='false'}">
<meta name="description" content="{content block='Page_Description' wysiwyg='false'}" /> <== page description, that you define while creating a page will show here
<meta name="date" content="{modified_date}" />
<meta name="lastupdate" content="{modified_date}" />
<meta name="revised" content="{modified_date}" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
<meta name="author" content="{$author}" /> <== name of authoer that you defined earlier in template will show here
<meta name="subject" content="Consultancy & Training"> <== replace it with the nature of your business
<meta name="copyright" content="{$copyright}" /> <==copyright information that you defined earlier in your template will show here.
<meta name="reply-to" content="{$email}" /> <== replace it with your official email address
<meta name="Geography" content="{$address}" /> <== type full address of your business entitiy
<meta name="Language" content="English" />
<META HTTP-EQUIV="CACHE-CONTROL" content="PUBLIC" />
<meta name="Copyright" content="{$copyright}" />
<meta name="Designer" content="{$developer}" /> <== name of developer/administrator will show hear
<meta name="Publisher" content="{$publisher}" /> <== name of publisher/owner will show here
<meta name="distribution" content="Global" />
<meta name="zipcode" content="ZIP CODE" />
<meta name="city" content="{$city}" />
<meta name="country" content="{$country}" />
<meta name="geo.placename" content="{$address}" />
<meta name="geo.region" content="Region i.e. Asia, Middle East etc" />
<meta name="geo.position" content="Coordinates taken from goole maps as per your address" />
<meta name="ICBM" content="Coordinates taken from goole maps as per your address" />
<link rel="schema.DC" href="http://purl.org/dc/elements/1.1/">
<link rel="schema.DCTERMS" href="http://purl.org/dc/terms/" />
<meta name="DC.Title" content="{$main_title nocache}">
<meta name="DC.Creator" content="{$author}">
<meta name="DC.Subject" content="{$main_title nocache}">
<meta name="DC.Description" content="{content block='Page_Description' wysiwyg='false'}">
<meta name="DC.Publisher" content="{$publisher}">
<meta name="DC.Contributor" content="{$developer}">
<meta name="DC.Date" content="{modified_date}">
<meta name="DC.Type" content="image">
<meta name="DC.Format" content="image/png">
<meta name="DC.Identifier" content="{$theme_path}/images/logo.png">
<link rel="DC.Source" href="{root_url}/">
<meta name="DC.Language" content="English">
<meta name="DC.Coverage" content="KSA, UK, USA, Pakistan">
<meta name="DC.Rights" content="{$copyright}">
<meta name="DC.Relation" content="{root_url}/" />
<meta property="og:title" content="{$main_title}" />
<meta property="og:type" content="article" />
<meta property="og:locale" content="en_US" />
<meta property="og:url" content="{root_url}/{$page_alias}" />
<meta property="og:image" content="{$theme_path}/images/logo.png" />
<meta property="og:site_name" content="{sitename}" />
<meta property="og:description" content="{content block='Page_Description' wysiwyg='false'}" />
<meta property="article:author" content="{$author}" />
<meta property="article:publisher" content="https://www.facebook.com/Your Facebook Page ID" />
<meta property="fb:page_id" content="https://www.facebook.com/Your Facebook Page ID" />
<meta property="fb:admins" content="https://www.facebook.com/Facebook Page Admin ID" />
<meta property="og:latitude" content="Coordinates taken from goole maps as per your address N Value" />
<meta property="og:longitude" content="Coordinates taken from goole maps as per your address E Value" />
<meta property="og:street-address" content="{$address}" />
<meta property="og:locality" content="{$city}" />
<meta property="og:region" content="Name of Region" />
<meta property="og:postal-code" content="POSTAL CODE" />
<meta property="og:country-name" content="{$country}" />
<meta property="og:email" content="{$email}" />
<meta property="og:phone_number" content="PHONE / Mobile Number" />
<meta property="og:fax_number" content="FAX Number" />
<meta itemprop="name" content="{$main_title}">
<meta itemprop="description" content="{content block='Page_Description' wysiwyg='false'}">
<meta itemprop="image" content="{$theme_path}/images/logo.png">

STEP ONE Explanation STEP TWO Explanation STEP THREE Explanation


Go to TOP STEP TWO Code STEP THREE Code

STEP TWO - Re-Format the Template

Copy below data in HEAD SECTION of your Template(s)

{strip}
{process_pagedata}
{cms_lang_info assign="nls"}
{$theme_path = "{uploads_url}/"}
{title assign="main_title"} 
{content assign="main_content"} 
{assign var='author' value=''}
{assign var='copyright' value=''} 
{assign var='publisher' value=''}
{assign var='developer' value=''} 
{assign var='city' value=''}
{assign var='country' value=''}
{assign var='address' value=''}
{assign var='email' value=''}
{cms_selflink dir="previous" assign="prev_page"}
{cms_selflink dir="next" assign="next_page"}
{share_data scope=parent vars="nls,theme_path,main_title,main_content,prev_page,next_page,author,copyright,publisher,developer,city,country,address,email" scope=global}
{/strip}<!DOCTYPE html>
<!--[if IE 8]><html lang="{$nls->htmlarea()}" dir="{$nls->direction()}" class="lt-ie9" prefix="og: http://ogp.me/ns#" itemscope itemtype="http://schema.org/LocalBusiness"> <![endif]-->
<!--[if gt IE 8]><!--> <html lang="{$nls->htmlarea()}" dir="{$nls->direction()}" prefix="og: http://ogp.me/ns#" itemscope itemtype="http://schema.org/LocalBusiness" > <!--<![endif]-->
<head>
<meta charset="{$nls->encoding()}" />
<title>{$main_title nocache} - {sitename}</title>
<meta name="HandheldFriendly" content="True" />
<meta name="MobileOptimized" content="320" />
<meta name="viewport" content="initial-scale = 1.0, maximum-scale = 1.0, user-scalable = no, width = device-width">
<meta http-equiv="cleartype" content="on" />
<meta name="msapplication-TileImage" content="{$theme_path}/images/icons/logoname-152x122.png" />
<meta name="msapplication-TileColor" content="#5C5A59" />
{metadata}
{if isset($canonical)}<link rel="canonical" href="{$canonical}" />{elseif isset($content_obj)}<link rel="canonical" href="{$content_obj->GetURL()}" />{/if}
<!--[if lt IE 9]><script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<script src="//css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js"></script><![endif]-->

{cms_stylesheet}
<!--<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,400,300,600">
<link rel="stylesheet" href="{$theme_path}/style.css" media="all">
<!--[if lte IE 7]><link rel="stylesheet" href="{$theme_path}/style.ie7.css" media="screen" /><![endif]-->

<script src="{$theme_path}/jquery.js"></script>
<script src="{$theme_path}/script.js"></script>

-->
<link rel="apple-touch-icon-precomposed" sizes="152x122" href="{$theme_path}/images/icons/logoname-152x122.png" />
<link rel="apple-touch-icon-precomposed" sizes="120x96" href="{$theme_path}/images/icons/logoname-120x96.png" />
<link rel="apple-touch-icon-precomposed" sizes="72x58" href="{$theme_path}/images/icons/logoname-72x58.png" />
<link rel="apple-touch-icon-precomposed" sizes="60x48" href="{$theme_path}/images/icons/logoname-60x48.png" />
<link rel="shortcut icon" sizes="196x157" href="{$theme_path}/images/icons/logoname-196x157.png" />
<link rel="shortcut icon" href="{$theme_path}/images/icons/logoname-60x48.png" />
<link rel="icon" href="{$theme_path}/images/icons/favicon.ico" type="image/x-icon" />
{cms_selflink dir="start" rellink="1"}
{cms_selflink dir="prev" rellink="1"}
{{cms_selflink dir="next" rellink="1"}

Copy below Data Before </body> tag in your Template(s)

{capture}{content block='SEO_Keywords' wysiwyg='false' assign="SEO_Keywords"}{/capture}
{capture}{content block='Page_Description' wysiwyg='false' asign="Page_Description"}{/capture}

STEP ONE Explanation STEP TWO Explanation STEP THREE Explanation


Go to TOP STEP TWO Code STEP THREE Code

STEP THREE - Global Settings ==>> Global MetaData Section

Copy/Paste following in Global Settings  -> Global MetaData Section - Yellow colored comments are explanations, Replace all bold values with your Own data.

<meta name="robots" content="index, follow" />
<meta name="title" content="{$main_title nocache}" />
<meta name='keywords' content="{content block='SEO_Keywords' wysiwyg='false'}">
<meta name='keypharases' content="{content block='SEO_Keywords' wysiwyg='false'}">
<meta name="description" content="{content block='Page_Description' wysiwyg='false'}" />
<meta name="date" content="{modified_date}" />
<meta name="lastupdate" content="{modified_date}" />
<meta name="revised" content="{modified_date}" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
<meta name="author" content="{$author}" />
<meta name="subject" content="Consultancy & Training">
<meta name="copyright" content="{$copyright}" />
<meta name="reply-to" content="{$email}" />
<meta name="Geography" content="{$address}" />
<meta name="Language" content="English" />
<META HTTP-EQUIV="CACHE-CONTROL" content="PUBLIC" />
<meta name="Copyright" content="{$copyright}" />
<meta name="Designer" content="{$developer}" />
<meta name="Publisher" content="{$publisher}" />
<meta name="distribution" content="Global" />
<meta name="zipcode" content="ZIP CODE" />
<meta name="city" content="{$city}" />
<meta name="country" content="{$country}" />
<meta name="geo.placename" content="{$address}" />
<meta name="geo.region" content="Region i.e. Asia, Middle East etc" />
<meta name="geo.position" content="Coordinates taken from goole maps as per your address" />
<meta name="ICBM" content="Coordinates taken from goole maps as per your address" />
<link rel="schema.DC" href="http://purl.org/dc/elements/1.1/">
<link rel="schema.DCTERMS" href="http://purl.org/dc/terms/" />
<meta name="DC.Title" content="{$main_title nocache}">
<meta name="DC.Creator" content="{$author}">
<meta name="DC.Subject" content="{$main_title nocache}">
<meta name="DC.Description" content="{content block='Page_Description' wysiwyg='false'}">
<meta name="DC.Publisher" content="{$publisher}">
<meta name="DC.Contributor" content="{$developer}">
<meta name="DC.Date" content="{modified_date}">
<meta name="DC.Type" content="image">
<meta name="DC.Format" content="image/png">
<meta name="DC.Identifier" content="{$theme_path}/images/logo.png">
<link rel="DC.Source" href="{root_url}/">
<meta name="DC.Language" content="English">
<meta name="DC.Coverage" content="{$country}">
<meta name="DC.Rights" content="{$copyright}">
<meta name="DC.Relation" content="{root_url}/" />
<meta property="og:title" content="{$main_title}" />
<meta property="og:type" content="article" />
<meta property="og:locale" content="en_US" />
<meta property="og:url" content="{root_url}/{$page_alias}" />
<meta property="og:image" content="{$theme_path}/images/logo.png" />
<meta property="og:site_name" content="{sitename}" />
<meta property="og:description" content="{content block='Page_Description' wysiwyg='false'}" />
<meta property="article:author" content="{$author}" />
<meta property="article:publisher" content="https://www.facebook.com/Your Facebook Page ID" />
<meta property="fb:page_id" content="https://www.facebook.com/Your Facebook Page ID" />
<meta property="fb:admins" content="https://www.facebook.com/Facebook Page Admin ID" />
<meta property="og:latitude" content="Coordinates taken from goole maps as per your address N Value" />
<meta property="og:longitude" content="Coordinates taken from goole maps as per your address E Value" />
<meta property="og:street-address" content="{$address}" />
<meta property="og:locality" content="{$city}" />
<meta property="og:region" content="Name of Region" />
<meta property="og:postal-code" content="POSTAL CODE" />
<meta property="og:country-name" content="{$country}" />
<meta property="og:email" content="{$email}" />
<meta property="og:phone_number" content="PHONE / Mobile Number" />
<meta property="og:fax_number" content="FAX Number" />
<meta itemprop="name" content="{$main_title}">
<meta itemprop="description" content="{content block='Page_Description' wysiwyg='false'}">
<meta itemprop="image" content="{$theme_path}/images/logo.png">

STEP ONE Explanation STEP TWO Explanation STEP THREE Explanation


Go to TOP STEP TWO Code STEP THREE Code

With Love from Pakistan to CMS Made Simple Community and everyone else who is gonna use it/change it in future for other PlatForms.

Wana Say Something? OK! .... Write me at qaiserikram@hotmail.com