05-Mar-2013, 06:55 PM
In Google Webmaster Tools, it complains that there are duplicate title tags and duplicate meta descriptions for pages that are paginated by the script (see attachment screenshots). This is the title tag and the meta description which is being duplicated on the commentics.org/project.php page:
It seems to be due to either the "cmtx_page" or the "cmtx_sort" parameter, and in some cases both! I'm wondering what the best solution is. For the "cmtx_page" parameter, maybe we can add the page number like this:
This could be done like so:
Regarding the "cmtx_sort" parameter, the sort feature displays the same content but in a different order so I wonder whether it would be best to add the ..
.. if the "cmtx_sort" parameter is in the URL, or maybe to use a canonical link instead?
Code:
<title>Commentics - Project</title>
<meta name="description" content="This is the project page for the PHP script Commentics. Ask a question about the programme or provide feedback."/>
It seems to be due to either the "cmtx_page" or the "cmtx_sort" parameter, and in some cases both! I'm wondering what the best solution is. For the "cmtx_page" parameter, maybe we can add the page number like this:
Code:
<title>Commentics - Project - Page 2</title>
This could be done like so:
PHP Code:
<title>Commentics - Project<?php if (isset($_GET['cmtx_page'])) { echo " - Page " . $_GET['cmtx_page']; } ?></title>
Regarding the "cmtx_sort" parameter, the sort feature displays the same content but in a different order so I wonder whether it would be best to add the ..
Code:
<meta name="robots" content="noindex"/>
.. if the "cmtx_sort" parameter is in the URL, or maybe to use a canonical link instead?