Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/joomla/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php Joomla-向JPaginator创建的链接添加锚点_Php_Joomla_Joomla3.2 - Fatal编程技术网

Php Joomla-向JPaginator创建的链接添加锚点

Php Joomla-向JPaginator创建的链接添加锚点,php,joomla,joomla3.2,Php,Joomla,Joomla3.2,我需要为标准Joomla paginator创建的链接添加一个锚。在某些地方,我工作的网站有很多内容,我希望当我点击分页器时,当页面被重新加载到我的列表中时 那么,如何将“site.com/index.php?start=3”转换为“site.com/index.php?start=3#content”?您必须在模板的html文件夹中创建pagination.php文件以覆盖默认输出。您可以在joomla3的protostar模板中找到此文件的示例,该模板位于templates/protosta

我需要为标准Joomla paginator创建的链接添加一个锚。在某些地方,我工作的网站有很多内容,我希望当我点击分页器时,当页面被重新加载到我的列表中时


那么,如何将“site.com/index.php?start=3”转换为“site.com/index.php?start=3#content”?

您必须在模板的
html
文件夹中创建
pagination.php
文件以覆盖默认输出。您可以在joomla3的protostar模板中找到此文件的示例,该模板位于
templates/protostar/html/pagination.php
中,您可以修改第180行,内容如下:

return "<li><a title=\"" . $item->text . "\" href=\"" . $item->link . "\" class=\"pagenav\">" . $display . "</a></li>";
返回“
  • ”;
    并对其进行如下修改:
    $item->link。“#内容\”

    更多关于