marty.net 1001 Postcards Love Love Love Meep Meep ZenZodiac DailyQuotation

YOU ARE HERE:
How to add "Page 2" to title of pages?

HOME

CPSHOP|

|

|

EMAIL MARTY
  marty.net message board
  « How to add "Page 2" to title of pages? »
Welcome, Guest. Please Login or Register.
12/12/17 at 14:23:20
Home Help Search Login Register
   marty.net message board
   About cpshop
   Customization Help
   How to add "Page 2" to title of pages?
(Moderator: Marty)
Pages: 1 Reply Notify of replies Send the topic Print 
   Author  Topic: How to add "Page 2" to title of pages?  (Read 466 times)
KaptainMyke.com
Gold Dragon
****

Gender: male
Posts: 210



KaptainMyke.com , Inc.
   

WWW E-Mail
How to add "Page 2" to title of pages?
« on: 02/15/12 at 21:08:57 »
Reply with quote Modify message

f we set the number of rows per page to 50 and cpshop makes a page 2 containing the next 50 products....how can we add a "- Page 2" onto the title of the next page?  This is to avoid duplicate title tags per Google's guidelines for ranking.
Logged

Mike "KaptainMyke" Sorensen
www.kaptainmyke.com
KaptainMyke.com, Inc.
CEO
KaptainMyke.com
Gold Dragon
****

Gender: male
Posts: 210



KaptainMyke.com , Inc.
   

WWW E-Mail
Re: How to add "Page 2" to title of pages?
« Reply #1 on: 03/10/12 at 16:25:56 »
Reply with quote Modify message

In cpshop.cgi, edit the following line of code:


where



Code:
  unless (@ARGV) {
       print "Content-Type: text/html\n\n";
   }
   print $html;


replace with


Code:
unless (@ARGV) {
   print "Content-Type: text/html\n\n";
}
if ($page > 1) {
   $html =~ s|</title>| - Page $page</title>|;
}
print $html;
Logged

Mike "KaptainMyke" Sorensen
www.kaptainmyke.com
KaptainMyke.com, Inc.
CEO
Pages: 1 Reply Notify of replies Send the topic Print 
Jump to:


marty.net message board (http://www.marty.net/cgi/marty/board/messageboard)

Powered by YaBB 1 Gold - Release (Yet Another Bulletin Board)
Copyright 2000-2001, X-Null. All Rights Reserved.