drd2551 2013-07-03 09:54
浏览 41

magento 2在一页上独立分页

On a category page I want to display 2 different type of products from the same category with pagination.

I would like to place 2 independent pagination on a single page, so URL should be something like this: ?p=2&p2=4 to not influence each other. Will be 2 product collections, for one(let it be main) I want to display toolbar in classic way: <?php echo $this->getToolbarHtml() ?>; block object will write 1 collection which pager will use; But how about second productCollerction? how to add pagination to it and not rewrite first one, and how to change parameter in url from p to p2 teach each pagination object to work with his own param. Hope I explain my issue good enough and thanks in advance

  • 写回答

1条回答 默认 最新

  • dsgdhf5674 2013-09-10 11:49
    关注

    To create 2 independent navigations you should dublicate all blocks related to navigations(place than in app/local) and rename them to be different from official one:

    and change value of $_GET['p'] in pages files. This worked for me. Thank you for responces :)

    评论

报告相同问题?

悬赏问题

  • ¥15 基于卷积神经网络的声纹识别
  • ¥15 Python中的request,如何使用ssr节点,通过代理requests网页。本人在泰国,需要用大陆ip才能玩网页游戏,合法合规。
  • ¥100 为什么这个恒流源电路不能恒流?
  • ¥15 有偿求跨组件数据流路径图
  • ¥15 写一个方法checkPerson,入参实体类Person,出参布尔值
  • ¥15 我想咨询一下路面纹理三维点云数据处理的一些问题,上传的坐标文件里是怎么对无序点进行编号的,以及xy坐标在处理的时候是进行整体模型分片处理的吗
  • ¥15 CSAPPattacklab
  • ¥15 一直显示正在等待HID—ISP
  • ¥15 Python turtle 画图
  • ¥15 stm32开发clion时遇到的编译问题