1

I read this link & even this also, but I am still confused. That's why I plan to ask here, Please confirm me with your answer.

My doubt is I have two pages: GridViewPage.php & ListViewPage.php having same content. So according to this in which page I have insert this code <link rel="canonical" href="which url I should put here"/>.

And for opening GridViewPage.php page URL looks like: http://example.com/article/show/abdominal-exercises/abdominal-crunch/79/87/list/.

& for opening GridViewPage.php page my URL looks like: http://example.com/article/show/abdominal-exercises/abdominal-crunch/79/87/grid/.

Note: 79/87 are the dynamic database table id's.

  • Please do not ask a question again after it has been closed. Edit the original question which can then be reopened if appropriate. – John Conde Jul 19 '13 at 17:52
1

For a.com/listview.php to be indexed instead gridview.php, you will add the following to gridview.php:

<link rel="canonical" href="http://www.a.com/listview.php" />

And the opposite for the opposite.

1

Something to note is that the url in the canonical tag should match your preferred version of your site, either www or non-www. So if your site is http://example.com then the canonical tag would be

<link rel="canonical" href="http://example.com/article/show/abdominal-exercises/abdominal-crunch/79/87/grid/" />
  • one doubt, if instead of ..../grid/ in the cononical url if i specified ``..../grid` then is this makes diffrence? – ashutosh Jul 20 '13 at 21:27
  • 2
    You should try and ensure the url in the canonical tag is exactly the same as the target url. – user29671 Jul 21 '13 at 11:50
  • @dan Here is my real-time implementation example: URL of my first page is like this http://mysite.com/article/show/abdominal-exercises/ball-pass/108/111/list and on my second similar content page,i specified as <link rel="canonical" href="http://mysite.com/article/show/abdominal-exercises/ball-pass/108/111/list"/> in the header. What you say dan,is this correct or i have doing mistake? – ashutosh Jul 24 '13 at 8:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.