I'm trying to customize the output of the mini-pager controller (the "next" and "previous" link with arrows) in a view. Actually, it is possible to insert custom text for "previous"-link in the view pager options, in the "tag" section. I tried to add inside the form (for a test), this:

<i class="icon-chevron-left"></i>

The resulting output is

<a href="front?page=1">&lt;i class="icon-chevron-right"&gt;&lt;/i&gt;</a>

So actually I think it filters HTML. Do you think it's possible to include HTML?


I just spent the last 2 hours trying to solve the same problem, using many different approaches, but I finally managed to get it right.

You just have to override the theme_pager_link function in your theme by copying the code content to template.php and change the return (last line), removing the check_plain() function of the $text variable, leaving it like:

return '<a' . drupal_attributes($attributes) . '>' . $text . '</a>';

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.