User tests: Successful: Unsuccessful:
Added ability to add the title of the next content item to the template.
I didn't change the template to not change existing sites.
Title |
|
I think it would be nice if we could choose what to show in the plugin params.
Have it default to the current prev/next behavior and change the default layout accordingly.
Then this PR would be great!
Thanks for your suggestion, I have added the plugin param.
So new testing instructions are:
1. Enable Show Navigation in Joomla Article options
2. Go to Plugin Manager -> Content - Page Navigation
3. Check that changing the option "Link text" does change the page navigation links below an article.
Tested and works as described. Nice work!
When I first read the title of this PR, I expected the option to be able to do something like 'Next' versus 'Next: Second Blog Post'. What are your thoughts on something like that? I do like this option as well, so I'm fine either way.
Please alpha-order the language strings.
When I first read the title of this PR, I expected the option to be able to do something like 'Next' versus 'Next: Second Blog Post'. What are your thoughts on something like that?
I think that the arrows are enough to indicate that the links are pointing to the next/previous post. So I would prefer only the title.
@infograf768 Was there a special reason we used the language strings JGLOBAL_GT
and JGLOBAL_LT
for this? Maybe RTL languages?
I just checked the arabic language pack and it doesn't have a different symbol in the JGLOBAL_GT
and JGLOBAL_LT
strings:./ar-AA.ini:328:JGLOBAL_GT=">"
./ar-AA.ini:357:JGLOBAL_LT="<"
So I think it should be safe to replace them with the icons.
So instead of <?php echo '<i class="icon-chevron-left"></i> ' . $row->prev_label; ?>
use something like
<?php $lang = JFactory::getLanguage();
$direction = $lang->isRTL() ? 'right' : 'left';
echo '<i class="icon-chevron-' . $direction . '"></i> ' . $row->prev_label;
(not tested)
I've fixed the RTL issue, can you please test again?
Yep, looks fine to me now.
Setting RTC as we have two tests.
Merged into 3.4-dev
. Thanks!
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2014-08-08 20:51:20 |
(OUTDATED - see comment below)
How to test this:
1. Enable Show Navigation in Joomla Article options
2. Open
plugins/content/pagenavigation/tmpl/default.php
3. Replace
JText::_('JPREV')
with$row->prev_title
4. Replace
JText::_('JNEXT')
with$row->next_title
5. Check that when you open an article in the frontend, the buttons at the bottom have the text of the next/previous article.