skip to Main Content

i have category pages with a lot of products.
for example :

https://www.cdsoft.co.il/index.php?id_category=218&controller=category&id_lang=3&p=3
https://www.cdsoft.co.il/index.php?id_category=218&controller=category&id_lang=3&p=4
https://www.cdsoft.co.il/index.php?id_category=218&controller=category&id_lang=3&p=4

they all have the same meta title .

i want to add to each meta title the string ” – page number XX”

HOW TO DO IT ?

2

Answers


  1. Chosen as BEST ANSWER

    I've found it :)

    i'm using blocklayered module , and there is a function call Ajax call. when i'm using blocklayered- the meta title comes from the ajax function :)

    so - with the help of Yaniv Mirel - in line 3174 , on module/blocklayered/blocklayered.php - line 3174 :

    'meta_title' => $meta_title . ' | ' . $this->l('page') . ' ' . $p . ' - ' . Configuration::get('PS_SHOP_NAME'),


  2. This problem is caused by Block Layered module on PrestaShop 1.6. To solve this you should add rel “Prev” and “Next” page tags to your category pages with more than 1 page. Please find this file:

    themes/[Your Theme]/header.tpl

    and add the code bellow before </head> tag:

    {if isset($p) AND $p}
       {if $start!=$stop}
          {if $p != 1}
             {assign var='p_previous' value=$p-1}
                <link rel="prev" href="{if isset($force_ssl) && $force_ssl}{$base_dir_ssl|escape:'html':'UTF-8'}{else}{$base_dir|escape:'html':'UTF-8'}{/if}{$request_uri|substr:1|regex_replace:'//(.*)/':''|regex_replace:'/?(.*)/':''|escape:'html':'UTF-8'}{$link->goPage($requestPage, $p_previous)|escape:'html':'UTF-8'}" />
          {/if}
          {if $pages_nb > 1 AND $p != $pages_nb}
             {assign var='p_next' value=$p+1}
                <link rel="next" href="{if isset($force_ssl) && $force_ssl}{$base_dir_ssl|escape:'html':'UTF-8'}{else}{$base_dir|escape:'html':'UTF-8'}{/if}{$request_uri|substr:1|regex_replace:'//(.*)/':''|regex_replace:'/?(.*)/':''|escape:'html':'UTF-8'}{$link->goPage($requestPage, $p_next)|escape:'html':'UTF-8'}" />
          {/if}
       {/if}
    {/if}
    

    You can also use this module which solves the issue automatically:
    https://addons.prestashop.com/en/seo-natural-search-engine-optimization/40888-seo-smo-assistant.html

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search