2

I am writing a new component for Joomla 2.5 and I am having problems wrapping my head around paginiation on the frontend(user site).

I have looked at the core component (com_content) to see how they do it and I am still unable to replicate the same. So when I put the line in my view.html.php file:

$pagination = $this->get('Pagination');

I get the JPagination Object and can print it out but I can not get them to display properly like below (how they do it in com_content)

echo $this->pagination->getPagesCounter();
echo $this->pagination->getPagesLinks();

What am I missing? What else do I need to have? Do I need to have more functions in my Models/thisview.php file?

Caleb Nance
  • 712
  • 5
  • 19

1 Answers1

2

Looks like you should be doing like so:

$pagination = $this->get('Pagination');
echo $pagination->getPagesCounter();
Søren Beck Jensen
  • 1,676
  • 1
  • 12
  • 22
  • You are right, I was looking all over the place and finally figured it out last night, I wanted to kick something, haha Thanks! I was going to delete this cause it was just me over looking it, but since you answered, I'll leave it up. Cheers! – Caleb Nance Jun 21 '12 at 12:59