[TASK] Add rel Attribute to pagination 43/46843/6
authorGianluigi Martino <gmartino27@gmail.com>
Tue, 23 Feb 2016 15:45:51 +0000 (16:45 +0100)
committerBenni Mack <benni@typo3.org>
Fri, 26 Feb 2016 05:59:55 +0000 (06:59 +0100)
Add rel="next" and rel="prev" to pagination for SEO optimization

Change-Id: Ia206b87042418f5bbe6de9a736753e9f9536ead6
Resolves: #73589
Releases: master
Reviewed-on: https://review.typo3.org/46843
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
typo3/sysext/fluid/Resources/Private/Templates/ViewHelpers/Widget/Paginate/Index.html

index 689adba..62916fa 100644 (file)
                        <li class="previous">
                                <f:if condition="{pagination.previousPage} > 1">
                                        <f:then>
-                                               <f:widget.link arguments="{currentPage: pagination.previousPage}" addQueryStringMethod="{configuration.addQueryStringMethod}" section="{configuration.section}"><f:translate key="widget.pagination.previous" /></f:widget.link>
+                                               <f:widget.link rel="prev" arguments="{currentPage: pagination.previousPage}" addQueryStringMethod="{configuration.addQueryStringMethod}" section="{configuration.section}" ><f:translate key="widget.pagination.previous" /></f:widget.link>
                                        </f:then>
                                        <f:else>
-                                               <f:widget.link addQueryStringMethod="{configuration.addQueryStringMethod}" section="{configuration.section}"><f:translate key="widget.pagination.previous" /></f:widget.link>
+                                               <f:widget.link rel="prev" addQueryStringMethod="{configuration.addQueryStringMethod}" section="{configuration.section}"><f:translate key="widget.pagination.previous" /></f:widget.link>
                                        </f:else>
                                </f:if>
                        </li>
@@ -61,7 +61,7 @@
                </f:if>
                <f:if condition="{pagination.nextPage}">
                        <li class="next">
-                               <f:widget.link arguments="{currentPage: pagination.nextPage}" addQueryStringMethod="{configuration.addQueryStringMethod}" section="{configuration.section}"><f:translate key="widget.pagination.next" /></f:widget.link>
+                               <f:widget.link rel="next" arguments="{currentPage: pagination.nextPage}" addQueryStringMethod="{configuration.addQueryStringMethod}" section="{configuration.section}"><f:translate key="widget.pagination.next" /></f:widget.link>
                        </li>
                </f:if>
        </ul>