[Skip to main content](#vessel-content)

#   Bug in pagination php?

##

- **[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")**
- [![svanschu's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/32672-svanschu "View svanschu's Profile") Topic Author
- [ Offline](/forum/user/32672-svanschu)

Less More

- Posts: 36
- Thank you received: 0
-
-

12 years 5 months ago [\#156368](#156368) by [svanschu](/forum/user/32672-svanschu "View svanschu's Profile")  *[Bug in pagination php?](/forum/31-development/868290-bug-in-pagination-php#156368 "-- url of the page with the problem -- :   mywebsite.com/mypage  -- HikaShop version -- : 2.3 -- Joomla version -- : 3.2.3 -- PHP version -- : x.x.x -- Browser(s) name and version -- : XXXXX x.x.x -- Error-message(debug-mod must be tuned on) -- : Error&#95;message  I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination&#95;list&#95;footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right.  Now I'm on frontend and because of the ! the pagination&#95;list&#95;footer would never be called. At my current understanding the code should look like this.  Am I wrong?")* was created by *[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")*

-- url of the page with the problem -- : [ mywebsite.com/mypage](http://mywebsite.com/mypage)
-- HikaShop version -- : 2.3
-- Joomla version -- : 3.2.3
-- PHP version -- : x.x.x
-- Browser(s) name and version -- : XXXXX x.x.x
-- Error-message(debug-mod must be tuned on) -- : Error_message

I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination_list_footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right. Code:

function getListFooter($minimum=20){ .... if(!$app-&gt;isAdmin()) return $this-&gt;_list_footer($list); ...

Now I'm on frontend and because of the ! the pagination_list_footer would never be called. At my current understanding the code should look like this.
Code:

function getListFooter($minimum=20){ .... if($app-&gt;isAdmin()) return $this-&gt;_list_footer($list); ...

Am I wrong?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMxLWRldmVsb3BtZW50Lzg2ODI5MC1idWctaW4tcGFnaW5hdGlvbi1waHA/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86541
- Thank you received: 14304
-
-

12 years 5 months ago [\#156403](#156403) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Bug in pagination php?](/forum/31-development/868290-bug-in-pagination-php#156403 "-- url of the page with the problem -- :   mywebsite.com/mypage  -- HikaShop version -- : 2.3 -- Joomla version -- : 3.2.3 -- PHP version -- : x.x.x -- Browser(s) name and version -- : XXXXX x.x.x -- Error-message(debug-mod must be tuned on) -- : Error&#95;message  I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination&#95;list&#95;footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right.  Now I'm on frontend and because of the ! the pagination&#95;list&#95;footer would never be called. At my current understanding the code should look like this.  Am I wrong?")*

No, it's not a bug. We purposely not allow the override to avoid issues with the pagination of the template which can sometimes create problems with HikaShop.
So you could remove these two lines to allow the override on the frontend, but it might not work properly with some templates.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMxLWRldmVsb3BtZW50Lzg2ODI5MC1idWctaW4tcGFnaW5hdGlvbi1waHA/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")**
- [![svanschu's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/32672-svanschu "View svanschu's Profile") Topic Author
- [ Offline](/forum/user/32672-svanschu)

Less More

- Posts: 36
- Thank you received: 0
-
-

12 years 5 months ago [\#156475](#156475) by [svanschu](/forum/user/32672-svanschu "View svanschu's Profile")  Replied by *[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")* on topic *[Bug in pagination php?](/forum/31-development/868290-bug-in-pagination-php#156475 "-- url of the page with the problem -- :   mywebsite.com/mypage  -- HikaShop version -- : 2.3 -- Joomla version -- : 3.2.3 -- PHP version -- : x.x.x -- Browser(s) name and version -- : XXXXX x.x.x -- Error-message(debug-mod must be tuned on) -- : Error&#95;message  I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination&#95;list&#95;footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right.  Now I'm on frontend and because of the ! the pagination&#95;list&#95;footer would never be called. At my current understanding the code should look like this.  Am I wrong?")*

I'm writing my own template based on blank template. What kind of issues you mean?

Then also this lines (32 pagination.php) need to be removed Code:

if(HIKASHOP_J30 &amp;&amp; $app-&gt;isAdmin())

but then I end at a problem I wrote in another topic. [ www.hikashop.com/support/forum/developme...gination-overri.html](http://www.hikashop.com/support/forum/development/868311-how-to-get-this-information-into-pagination-overri.html)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMxLWRldmVsb3BtZW50Lzg2ODI5MC1idWctaW4tcGFnaW5hdGlvbi1waHA/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26400
- Thank you received: 4079
-
- [](http://obsi.dev)
-

12 years 5 months ago [\#156541](#156541) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[Bug in pagination php?](/forum/31-development/868290-bug-in-pagination-php#156541 "-- url of the page with the problem -- :   mywebsite.com/mypage  -- HikaShop version -- : 2.3 -- Joomla version -- : 3.2.3 -- PHP version -- : x.x.x -- Browser(s) name and version -- : XXXXX x.x.x -- Error-message(debug-mod must be tuned on) -- : Error&#95;message  I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination&#95;list&#95;footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right.  Now I'm on frontend and because of the ! the pagination&#95;list&#95;footer would never be called. At my current understanding the code should look like this.  Am I wrong?")*

Hi,

If you want to override the items in the backend too, yes.

Do not remove the line but use instead Code:

if(HIKASHOP_J30)

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMxLWRldmVsb3BtZW50Lzg2ODI5MC1idWctaW4tcGFnaW5hdGlvbi1waHA/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")**
- [![svanschu's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/32672-svanschu "View svanschu's Profile") Topic Author
- [ Offline](/forum/user/32672-svanschu)

Less More

- Posts: 36
- Thank you received: 0
-
-

12 years 5 months ago [\#156588](#156588) by [svanschu](/forum/user/32672-svanschu "View svanschu's Profile")  Replied by *[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")* on topic *[Bug in pagination php?](/forum/31-development/868290-bug-in-pagination-php#156588 "-- url of the page with the problem -- :   mywebsite.com/mypage  -- HikaShop version -- : 2.3 -- Joomla version -- : 3.2.3 -- PHP version -- : x.x.x -- Browser(s) name and version -- : XXXXX x.x.x -- Error-message(debug-mod must be tuned on) -- : Error&#95;message  I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination&#95;list&#95;footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right.  Now I'm on frontend and because of the ! the pagination&#95;list&#95;footer would never be called. At my current understanding the code should look like this.  Am I wrong?")*

In this special case the frontend would not be overriden with app-&gt;isAdmin()

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMxLWRldmVsb3BtZW50Lzg2ODI5MC1idWctaW4tcGFnaW5hdGlvbi1waHA/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86541
- Thank you received: 14304
-
-

12 years 5 months ago [\#156658](#156658) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Bug in pagination php?](/forum/31-development/868290-bug-in-pagination-php#156658 "-- url of the page with the problem -- :   mywebsite.com/mypage  -- HikaShop version -- : 2.3 -- Joomla version -- : 3.2.3 -- PHP version -- : x.x.x -- Browser(s) name and version -- : XXXXX x.x.x -- Error-message(debug-mod must be tuned on) -- : Error&#95;message  I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination&#95;list&#95;footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right.  Now I'm on frontend and because of the ! the pagination&#95;list&#95;footer would never be called. At my current understanding the code should look like this.  Am I wrong?")*

What we're saying basically is that templates made for Joomla and which override the joomla pagination for example don't expect to have to handle the $this-&gt;hikaSuffix and $this-&gt;form variables. So we can't allow the override on the frontend by default because it would break with most templates.
What I would recommend to do is to create a file templates/YOUR_TEMPLATE/html/com_hikashop/administrator/helpers/pagination.override.php
which would first include_once our helper.pagination file and then implement a class hikashopPaginationHelperOverride extending our hikashopPaginationHelper class so that you can redefine what you want easily in the pagination of HikaShop in your template.
That way, you have the total control on what to do and what to change in the code of the HikaShop pagination.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMxLWRldmVsb3BtZW50Lzg2ODI5MC1idWctaW4tcGFnaW5hdGlvbi1waHA/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")**
- [![svanschu's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/32672-svanschu "View svanschu's Profile") Topic Author
- [ Offline](/forum/user/32672-svanschu)

Less More

- Posts: 36
- Thank you received: 0
-
-

12 years 5 months ago [\#159739](#159739) by [svanschu](/forum/user/32672-svanschu "View svanschu's Profile")  Replied by *[svanschu](/forum/user/32672-svanschu "View svanschu's Profile")* on topic *[Bug in pagination php?](/forum/31-development/868290-bug-in-pagination-php#159739 "-- url of the page with the problem -- :   mywebsite.com/mypage  -- HikaShop version -- : 2.3 -- Joomla version -- : 3.2.3 -- PHP version -- : x.x.x -- Browser(s) name and version -- : XXXXX x.x.x -- Error-message(debug-mod must be tuned on) -- : Error&#95;message  I just wanted to override the pagination.php which is supported since 2.1. I wondered why the pagination&#95;list&#95;footer didn't get called. I found this code in pagination.php which should prevent the override if you are in admin interface, if I understand it right.  Now I'm on frontend and because of the ! the pagination&#95;list&#95;footer would never be called. At my current understanding the code should look like this.  Am I wrong?")*

Thx for the hint. I've done the most stuff now by str_replace.

only the this-&gt;admin I mentioned in the first post I changed now in the hika pagination

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzMxLWRldmVsb3BtZW50Lzg2ODI5MC1idWctaW4tcGFnaW5hdGlvbi1waHA/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.060 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
