Page number (x/y) in title for SEO purposes Page number (x/y) in title for SEO purposes
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Page number (x/y) in title for SEO purposes

Started by zapotex, October 22, 2011, 06:35:03 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

zapotex

Hi all!

I'm trying to make sure I don't have pages with duplicate titles in my gallery. When, in a category, there are more albums than fit in a page, the two pages:

http://...&page=1
http://...&page=2

have the exact same title. I was wondering whether it was possible to create a custom token {PAGENUMBER}, that is:

"" (empty) if the albums fit in a single page
" - (x/y)" if the albums do not fit a single page

Then, in template.html, I will use:

<title>{TITLE}{PAGENUMBER}</title>

Is it possible? Thanks so much!

Αndré

I've currently no access to my testbed, that's why I can give you just general advices. Please search the board of how using custom tokens in Coppermine, we had some threads recently (you'll have to edit the pageheader function). In that function you have to read the page parameter from the URL, get the number of albums in that category / the number of files in that album and then calculate the number of displayed items. Now you're able to compare that values and determine if you need to extend the page title.

If you cannot solve that yourself, just let me know.

kubizo

Hi André! Thanks a lot for the suggestion! I will try!

Have a great day!

K