4images Issues / Ausgaben > Discussion & Troubleshooting
Google Canonical
sathishIPL:
--- Quote ---site.com/stuff/cat-nokia-7710-themes-27.htm?page=2
site.com/stuff/cat-nokia-7710-themes-27.htm?page=3
--- End quote ---
I mean how this pages are coming to you .It might come if you click the pagination in the comment system?
by clicking the next page in the comment?
khansahib:
I have done it :) 8)
bergblume:
--- Quote from: khansahib on July 15, 2011, 12:36:53 PM ---I have done it :) 8)
--- End quote ---
can you pls. let us know your solution and what you have changed in which files? thx!
khansahib:
Here is how its done :).
open index.php file and find
--- Code: ---include(ROOT_PATH.'includes/page_header.php');
--- End code ---
Paste the following just before the above line.
--- Code: ---if(isset($_GET['page'])) {
$site_template->register_vars("google_con_url", '<link rel="canonical" href="' . ROOT_PATH . '/' . $_SERVER['REQUEST_URI'] . '" />');
}
else {
$site_template->register_vars("google_con_url", '');
}
--- End code ---
and insert
--- Code: ---{google_con_url}
--- End code ---
in header of your template. Make sure its between <head> tags.
bergblume:
Hi - thanx
I assume that the code is inserted in the file details.php - right?
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version