Pagination Error From Helix - Question | JoomShaper
Black Friday sale is live with flat 50% OFF. Sale ends soon! Grab your deal now!

Pagination Error From Helix

Karen Dunne

Karen Dunne

Helix Framework 7 months ago

For pagination, the link.php file, i.e. /plugins/system/helixultimate/overrides/layouts/joomla/pagination/link.php produces the following text on the front end, see screenshot: https://monosnap.com/file/Lvo0wiQzCWaKsLnKGdioQ7dvhHB8Bf

the value of $item->text for the next link was invalid

So, I changed line 35 by adding the following: $item->text = 'Next'; See screenshot: https://monosnap.com/file/rBEj1X2VIQrYyT7PYhXTK18W8dEjog

I had changed this six months ago but then it was overridden on the last update. Can this be corrected for the next Helix release?

0
13 Answers
Ziaul Kabir
Ziaul Kabir
Accepted Answer
Support Agent 7 months ago #190195

Hello Karen,

There are no issues on our end—it’s possible the issue was created on your side. You can try following your previous steps, or if you need assistance, feel free to let me know.

Also, please make sure you have updated Helix Ultimate to the latest version.

Best regards,

0
Karen Dunne
Karen Dunne
Accepted Answer
7 months ago #190230

I do believe it IS an issue with Helix. As I stated, it worked when I edited the link.phph file as stated, and doesn't work with Helix 2.1.2, which is the current version that I am using. I took the time to find the solution AND write it to you, so I request that you give my effort attention.

0
Ziaul Kabir
Ziaul Kabir
Accepted Answer
Support Agent 7 months ago #190236

Could you please share temporary administrator access to your Joomla backend? You can provide the credentials securely in the hidden content section. Also, please take a full backup of your site before we make any changes.

Once I have access, I’ll investigate further and see what’s causing the issue. Let me know once you’ve shared the details!

Best Regards,

0
Karen Dunne
Karen Dunne
Accepted Answer
6 months ago #191717

Hello Ziaul,

I delayed in sending login credentials because I was using a copy of the site for a presentation at JDay USA. I needed to wait until that was done.

You will see the error in the pagination on this page: https://mavendesignstudio-demo.com/jdayusa2025/news I removed my fix so you can see the error.

Please see credentials.

0
Ziaul Kabir
Ziaul Kabir
Accepted Answer
Support Agent 6 months ago #191863

Hello Karen,

This issues comes from anything else from your code modification, I didn't see any issues on our system like this. But there fore i send it to our dev to check.

Thanks for your information.

0
Karen Dunne
Karen Dunne
Accepted Answer
3 weeks ago #208157

After updating Helix again, the issue is back. Please see the pagination displayed at the bottom of the blog articles on this page: https://rtaarchitects.com/news

The site is currently using Helix 2.1.3

0
Ziaul Kabir
Ziaul Kabir
Accepted Answer
Support Agent 3 weeks ago #208462

Could you please share temporary administrator access to your Joomla backend? You can provide the credentials securely in the hidden content section. Also, please take a full backup of your site before we make any changes.

Once I have access, I’ll investigate further and see what’s causing the issue. Let me know once you’ve shared the details!

Best regards,

0
Karen Dunne
Karen Dunne
Accepted Answer
3 weeks ago #208589

Thank you, Ziaul. The credentials are posted.

0
Ziaul Kabir
Ziaul Kabir
Accepted Answer
Support Agent 3 weeks ago #208642

Issues fixed.

Thanks

0
Karen Dunne
Karen Dunne
Accepted Answer
3 weeks ago #208662

Hi Ziaul, I saw from the User Action Log that you've taken many steps, although I don't know what was done to fix the issue. There's now a new issue though. Did you see what it changed into? https://rtaarchitects.com/news, i.e. https://loom.com/i/cda2d17a33f74955b807ef23faa61a68 This happens only on page 1 of the pagination.

<span class="fas fa-angle-double-left" aria-hidden="true"></span> <span class="fas fa-angle-left" aria-hidden="true"></span>

0
Ziaul Kabir
Ziaul Kabir
Accepted Answer
Support Agent 3 weeks ago #208668

I have fixed this link.php code in this path: (JRoot/plugins/system/helixultimate/overrides/layouts/joomla/pagination/link.php)

Here is the code:

<?php
defined('JPATH_BASE') or die;

use Joomla\CMS\Factory;
use Joomla\CMS\Language\Text;

// Ensure $displayData['data'] exists
$item = isset($displayData['data']) ? $displayData['data'] : null;
if (!$item) return;

$display = isset($item->text) ? $item->text : '';
$app = Factory::getApplication();

$icon = null;
$aria = '';

// Determine icon and ARIA label
switch ((string)$display) {
    case Text::_('JLIB_HTML_START'):
        $icon = $app->getLanguage()->isRtl() ? 'fas fa-angle-double-right' : 'fas fa-angle-double-left';
        $aria = Text::_('JLIB_HTML_START');
        break;

    case Text::_('JPREV'):
        $display = Text::_('JPREVIOUS');
        $icon = $app->getLanguage()->isRtl() ? 'fas fa-angle-right' : 'fas fa-angle-left';
        $aria = Text::_('JPREVIOUS');
        break;

    case Text::_('JNEXT'):
        $icon = $app->getLanguage()->isRtl() ? 'fas fa-angle-left' : 'fas fa-angle-right';
        $aria = Text::_('JNEXT');
        break;

    case Text::_('JLIB_HTML_END'):
        $icon = $app->getLanguage()->isRtl() ? 'fas fa-angle-double-left' : 'fas fa-angle-double-right';
        $aria = Text::_('JLIB_HTML_END');
        break;

    default:
        $icon = null;
        $aria = Text::sprintf('JLIB_HTML_GOTO_PAGE', (string)$display);
        break;
}

// Wrap icon if it exists (do NOT escape HTML)
if ($icon !== null) {
    $display = '<span class="' . $icon . '" aria-hidden="true"></span>';
}

// Determine classes and link
$class = '';
$link = '';

// Current page
if (!empty($item->active) && $item->active) {
    $class = 'active';
    $aria = Text::sprintf('JLIB_HTML_PAGE_CURRENT', (string)$display);
    echo '<li class="page-item ' . $class . '" aria-current="page">';
    echo '<span class="page-link" aria-label="' . htmlspecialchars($aria, ENT_QUOTES, 'UTF-8') . '">' . $display . '</span>';
    echo '</li>';

// Clickable link
} elseif (!empty($displayData['active']) && $displayData['active']) {
    if ($app->isClient('administrator')) {
        $limit = isset($item->base) ? (int)$item->base : 0;
        $prefix = isset($item->prefix) ? $item->prefix : '';
        $link = 'href="#" onclick="document.adminForm.' . htmlspecialchars($prefix, ENT_QUOTES, 'UTF-8') . 'limitstart.value=' . $limit . '; Joomla.submitform();return false;"';
    } else {
        $link = isset($item->link) ? 'href="' . htmlspecialchars($item->link, ENT_QUOTES, 'UTF-8') . '"' : '';
    }

    echo '<li class="page-item">';
    echo '<a class="page-link" ' . $link . ' aria-label="' . htmlspecialchars(strip_tags($aria), ENT_QUOTES, 'UTF-8') . '">';
    echo $display;
    echo '</a></li>';

// Disabled link
} else {
    $class = 'disabled';
    echo '<li class="page-item ' . $class . '">';
    echo '<span class="page-link" aria-hidden="true">' . $display . '</span>';
    echo '</li>';
}

Thanks

0
Karen Dunne
Karen Dunne
Accepted Answer
3 weeks ago #208711

Thank you, Ziaul. It looks good now.

Will the link.php path be overwritten when there is an update with Helix?

0
Ziaul Kabir
Ziaul Kabir
Accepted Answer
Support Agent 2 weeks ago #208782

It’s great to hear that your issue has been resolved. Actually from our end, there is no issues. Maybe any of your files cause this issues. If everything is working fine now, please mark the question as complete by accepting any of our answers.

Thank you!

0