Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

KissMT Dynamic SEO Meta Tags


FWR Media

Recommended Posts

KissMT Dynamic SEO Meta Tags

 

Compatibility: PHP5.2+

 

Like everything else in SEO meta tags have shrunk in importance (except the title which is still very important), however we all except that we still need them. There are many meta/header tag contributions available so why another one?

 

I have always used cDynamic meta tags which is now very old, the contributions out there are either too simplistic or far too complicated (The KISS part of the name is from the well known saying "Keep It Simple Stupid!") so I felt there is room for one which is extremely simple to install on a new or modded shop and which doesn't overcomplicate what is after all a relatively simple thing, but .. which will auto generate meaningful meta tags output.

 

 

 

Installation:

 

Like everything I produce I try to keep installation simple and where possible changes to core osCommerce files to a minimum, this is no exception. Other than changing: -

 

<title><?php echo TITLE; ?></title>

 

To ..

 

<?php include_once DIR_WS_MODULES . 'kiss_meta_tags/kiss_meta_tags.php'; ?>

 

in the catalog files; there are no changes to osCommerce AT ALL. Installation can therefore be measured in minutes or even seconds and no conflicts guaranteed. (other meta tag contributions may have already changed the <title></title> but this is the only possible conflict). There is also no database install.

 

 

 

Ease of use and dynamic ability:

 

Some people don't want or have the time to intricately set up each osCommerce page, KissMT does it dynamically. Every single catalog file where you swap out the <title></title> for the KissMT code will produce meta tags automatically with no input from you.

 

 

 

Different handling for certain pages:

 

Obviously some pages require more attention by KissMT than others .. the prime examples are index.php (which handles categories, category product listings, manufacturers listings, and product_info.php which handles the all important products.

 

For these types of pages KissMT has modules, simply put if there is a file in "modules" with the same name as the page being loaded then KissMT will use these files to generate the meta tags.

 

I'll give just two examples here from the stock osCommerce RC2a install:

 

1) category: www.mysite.com/index.php?cPath=3_10

 

Title:

 

Action - DVD Movies

 

Description:

 

Action, DVD Movies. The Replacement Killers,The Matrix,Under Siege,Under Siege 2 - Dark Territory,Fire Down Below,Die Hard With A Vengeance,Lethal Weapon,Speed,Speed 2 Cruise Control.

 

Keywords: action,dvd,movies,replacement,killers,matrix,siege,dark,territory,fire,die,hard,vengeance,lethal,weapon,speed,cruise,control

 

 

 

2) Product: www.mysite.com/product_info.php?cPath=3_10&products_id=4

 

Title:

 

The Replacement Killers - DVD-RPMK - Action - DVD Movies - by Microsoft

Description:

 

The Replacement Killers, DVD-RPMK, Action, DVD Movies, by Microsoft. Regional Code 2 Japan, Europe, Middle East, South Africa . Languages English, Deutsch. Subtitles English, Deutsch, Spanish. Audio Dolby Surround 5.1. Picture Format 16 9 Wide-Screen. Length approx 80 minutes. Other Interactive Menus, Chapter Selection, Subtitles more languages ..

 

Keywords:

 

replacement,killers,dvd-rpmk,action,dvd,movies,microsoft,regional,code,japan,europe,middle,east,south,africa,languages,english,deutsch,subtitles,spanish,audio,dolby,surround,picture,format,wide-screen,minutes,interactive,menus,chapter,selection

 

 

 

Pages that have modules:

 

index.php, product_info.php, specials.php, new_products.php. Modules can be added e.g. for information pages, articles, newsletters, faq desk etc.

 

 

 

Other pages that will just use HEADING_TITLE or the filename:

 

conditions.php, privacy.php, advanced_search.php, advanced_search_result.php etc. etc.

 

 

 

Multi language:

 

Multi language capable as standard. The "stop words" (words to remove from the keywords .. like "a" "of" "the" etc.) are language specific so there would be e.g. stopwords for English and perhaps German and Spanish and so on to ensure the keywords are unpolluted by irrelevant stop words.

 

 

Queries - efficiency and shop size:

 

I have chosen for KissMT to run a query instead of using the values already loaded by osCommerce, the reasoning behind this is simply that to do this any other way would have meant multiple changes to osCommerce files which I was keen to avoid. When a page loads for the first time KissMT will run the relevant query to gain its values, but after this the values are cached. Therefore once all pages have been loaded KissMT uses no queries whatsoever it just has to load a 1kb/2kb file .. very fast .. very efficient. Even the largest of shops won't notice it is there.

 

 

 

Future development:

 

I intend the contribution to be in two distinct parts:

 

1) As above, a ridiculously easy to install dynamic system which can be installed standalone, without any of the below.

 

2) Optional additons which will require file changes, these will be likely to include: -

 

  • The ability to specifically set the meta info for pages via admin.
  • Additions of category text/manufacturers text which could/would override the dynamic tags.
  • Admin settings

 

What I will not be adding:

 

I will not be adding any seo tools like keyword density etc. It is my opinion that if you are serious about your seo then you should be using the plethora of specifically designed seo analysis tools that are available on the web. Most of these are far more capable and complex than anything that could be incorporated into a meta tag contribution. You should know if the words in your title tag appear on your page and whether your key words are in <h1> <h2> tags on the page and not just in divs or tds. The 2) options would allow users to specifically set tags if required.

 

Fancy helping by testing?

 

The dynamic system is in the beta test phase, if anyone would like/is willing to beta test this then please post here and I will send you the initial package when it is ready (next few days).

When people beta test it helps me greatly in producing a more solid initial offering .. one tester i.e. me is just not good enough.

 

 

 

I would also appreciate any comments here about the concept and what you feel should or shouldn't be included.

Edited by FWR Media
Link to comment
Share on other sites

An initial beta package is available for testing if anyone fancies the idea of helping my to test this.

Link to comment
Share on other sites

Interesting .. no willing beta testers for this on these forums.

 

Luckily for me I have people who were willing to beta test elsewhere.

 

The update is ..

 

No bugs yet found.

 

Added canonical tags to remove/protect against duplicate penalties.

Link to comment
Share on other sites

I`m willing to beta test this. Like you mentioned in the USU 5 thread, the one i currently use works with that PHP_SELF code that isn`t the best thing...

 

Sent the link via PM.

Link to comment
Share on other sites

New revision is KissMT_1.0_r25_[PACKAGED_BETA]_dev.zip

 

If you had the link to an older revision just change the filename to the above to download it.

 

This is now packaged with full instructions and very close to a full release..

 

I have added my usual "Drop on Top" install so people wishing to test can do the 2 minute full install.

 

Only on a FRESH RC2a

 


  •  
  • Drop the files on top.
  • Run the installer
  • Done!

Edited by FWR Media
Link to comment
Share on other sites

This sounds great. Looks like the metatag contribution I've allways been looking for!

I see you will implement the manufacturer, model no. categorie, sub-category and product name so it shows in the title tag.

 

Looking forward to the release!

 

You could beta test it Wim .. it's pretty much production ready now.

Edited by FWR Media
Link to comment
Share on other sites

No problem! Pls send me the link to the files and I'll install it right away

 

Link sent.

Link to comment
Share on other sites

For testers who already have the package and are using languages other than English.

 

I have just created a zipfile of some more language stopwords .. covering ..

 

Spanish

German

Dutch

Danish

Italian

Romanian

French

 

I believe these will be far from complete and will need adding to .. but it's a start :)

 

Check the naming of the file for your language as it MUST match the language in osCommerce e.g.

 

If your language in osCommerce is deusche and the stopwords file is named german_stopwords.ini then it will never get loaded.

 

The filename is stopwords.zip

 

This can be downloaded using the same url that you used for downloading the package but replace the filename with stopwords.zip.

Edited by FWR Media
Link to comment
Share on other sites

Installing this contribution was only 2 minutes work.

Uninstalling header tags SEO however took me 2 hours to get osCommerce working again...

 

About the contribution:

It seems like no meta tags are produced here.

 

see the source of a product_info page (the same happens on the index page)

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
<html dir="LTR" lang="nl">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<base href="http://localhost/catalog/">

<!-- start get_javascript(applicationtop2header) //-->
<script language="javascript"><!--
function popupWindow(url) {
 window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=100,height=100,screenX=150,screenY=150,top=150,left=150')
}
//--></script>
<!-- end get_javascript(applicationtop2header) //-->

<link rel="stylesheet" type="text/css" href="/catalog/includes/sts_templates/photo/stylesheet.css">
<script type="text/javascript" src="includes/js/prototype.js"></script>
<script type="text/javascript" src="includes/js/scriptaculous.js?load=effects"></script>
<script type="text/javascript" src="includes/js/lightbox.js"></script>
<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico">
</head>

 

I installed the contribution on my local testing server.

Maybe it has to do with the permission of the cache folder??

 

Kind regards

wim

Link to comment
Share on other sites

Installing this contribution was only 2 minutes work.

Uninstalling header tags SEO however took me 2 hours to get osCommerce working again...

 

About the contribution:

It seems like no meta tags are produced here.

 

see the source of a product_info page (the same happens on the index page)

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
<html dir="LTR" lang="nl">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<base href="http://localhost/catalog/">

<!-- start get_javascript(applicationtop2header) //-->
<script language="javascript"><!--
function popupWindow(url) {
 window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=100,height=100,screenX=150,screenY=150,top=150,left=150')
}
//--></script>
<!-- end get_javascript(applicationtop2header) //-->

<link rel="stylesheet" type="text/css" href="/catalog/includes/sts_templates/photo/stylesheet.css">
<script type="text/javascript" src="includes/js/prototype.js"></script>
<script type="text/javascript" src="includes/js/scriptaculous.js?load=effects"></script>
<script type="text/javascript" src="includes/js/lightbox.js"></script>
<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico">
</head>

 

I installed the contribution on my local testing server.

Maybe it has to do with the permission of the cache folder??

 

Kind regards

wim

 

Are you running on php 5.2+ ?

Link to comment
Share on other sites

Yes, 5.2.0

 

Ok try this see if it outputs the issue ..

 

catalog/includes/application_top.php

 

Find ..

 error_reporting(E_ALL & ~E_NOTICE);

 

Change to ..

 

  //error_reporting(E_ALL & ~E_NOTICE);
 // TEMPORARY
 error_reporting( E_ALL );
 // END TEMPORARY

 

See if it outputs a decent error. I have a feeling that 5.2.0 may be too low .. that was way back in 2006 the current stable version is 5.2.12

 

[edit] I loaded php 5.2.0 .. works fine [/edit]

Edited by FWR Media
Link to comment
Share on other sites

This shows a whole lot of errors! I don't know if this is normal?

The problem will more then likely be the STS contribution

 

These are some of the errors shown in the header:

 

 

Notice: Undefined index: sts_debug in D:\Conus Test Site\wamp\www\catalog\includes\classes\sts.php on line 64

 

Notice: Undefined index: sts_template in D:\Conus Test Site\wamp\www\catalog\includes\classes\sts.php on line 69

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_TITLE - assumed 'MODULE_STS_DEFAULT_TITLE' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 28

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_DESCRIPTION - assumed 'MODULE_STS_DEFAULT_DESCRIPTION' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 29

 

Notice: Undefined property: sts_default::$enabled in D:\Conus Test Site\wamp\www\catalog\includes\classes\sts.php on line 94

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_TITLE - assumed 'MODULE_STS_DEFAULT_TITLE' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 28

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_DESCRIPTION - assumed 'MODULE_STS_DEFAULT_DESCRIPTION' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 29

Link to comment
Share on other sites

This shows a whole lot of errors! I don't know if this is normal?

The problem will more then likely be the STS contribution

 

These are some of the errors shown in the header:

 

 

Notice: Undefined index: sts_debug in D:\Conus Test Site\wamp\www\catalog\includes\classes\sts.php on line 64

 

Notice: Undefined index: sts_template in D:\Conus Test Site\wamp\www\catalog\includes\classes\sts.php on line 69

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_TITLE - assumed 'MODULE_STS_DEFAULT_TITLE' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 28

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_DESCRIPTION - assumed 'MODULE_STS_DEFAULT_DESCRIPTION' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 29

 

Notice: Undefined property: sts_default::$enabled in D:\Conus Test Site\wamp\www\catalog\includes\classes\sts.php on line 94

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_TITLE - assumed 'MODULE_STS_DEFAULT_TITLE' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 28

 

Notice: Use of undefined constant MODULE_STS_DEFAULT_DESCRIPTION - assumed 'MODULE_STS_DEFAULT_DESCRIPTION' in D:\Conus Test Site\wamp\www\catalog\includes\modules\sts\sts_default.php on line 29

 

Sadly tons of errors with error_reporting set E_ALL is pretty standard with osCommerce shops I develop as error_reporting( E_ALL | E_STRICT ) to ensure the sites I work on are totally error free. error_reporting(E_ALL & ~E_NOTICE) hides a multitude of sins.

 

Could you try this please .. make sure you are loading a products page where the tags are not showing then see if there is an error with the word "kiss" in it.

Edited by FWR Media
Link to comment
Share on other sites

Having seen those errors I now obviously realise you are using STS which I avoid like the plague.

 

Quite possibly instead of the catalog files the title /title code may need to be in a template or something?

 

I am afraid I do not develop systems with STS in mind so I could be at a loss here.

Edited by FWR Media
Link to comment
Share on other sites

No, I don't see any error that has to do with this contribution

So you did your job just fine :)

 

When I turn of STS I can see that the meta tags are showing up.

So the only thing that needs to be done is the link with STS

 

Can I suggest that you do a quick post in the STS support thread and see if we can find out the correct files to add title /title code?

 

although I feel that the other mods to index.php re: h1 tags will get stuffed by STS also.

 

It would help me out too for future STS users.

Edited by FWR Media
Link to comment
Share on other sites

Probably includes/modules/sts_inc/general.php

and

includes/header.php

 

Header Tags SEO uses these files too.

Unfortunately I'm not that good with STS (I tried converting the code for that contribution to this one)

I wasn't able to fix it right away. I'll give it another go tomorrow.

Link to comment
Share on other sites

Canonical tags are only added when a oscid is found in the url? Or also when a language or currency is found?

 

This contri seems to work perfectly so far. Dead easy installation. Only thing i still have to do is remove the header tag contri i used before.

Link to comment
Share on other sites

Canonical tags are only added when a oscid is found in the url? Or also when a language or currency is found?

 

This contri seems to work perfectly so far. Dead easy installation. Only thing i still have to do is remove the header tag contri i used before.

 

It is rather more complex than that.

 

canonical links show for ..

 

language

osCsid

currency

paging (splitpage results) (although mostly a noindex follow tag here)

 

also

 

Canonical links show where there is uneccessary querystring e.g.

 

When you go from categories to reach a product cPath is appended.

 

If you go from the manufacturers dropdown to a product manufacturers_id is appended etc. etc.

 

Glad that you like it and found it easy to install.

 

Have you seen the new stopwords Onno?

 

http://www.oscommerce.com/forums/topic/350554-kissmt-dynamic-seo-meta-tags/page__view__findpost__p__1468602

 

They will probably be laughable to a Dutchman however :)

Edited by FWR Media
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...