by
KK » Fri Mar 04, 2016 12:59 am
The k_is_page check is redundant as pages fetched by <cms:pages> will always show this as true.
So after removing that check, we are essentially left with the following -
- Code: Select all
<cms:pages masterpage='users/index.php' id=id >
<cms:reverse_related_pages 'users' masterpage='users/nor/outbox-employee.php' >
<cms:show k_page_title />
..
</cms:reverse_related_pages>
</cms:pages>
Since the <cms:show k_page_title /> is being used within the inner <cms:reverse_related_pages> block, it will override the variable with the same name set by the outer <cms:pages> block.
To use the variable set by the outer block, we can save it into another variable as follows -
- Code: Select all
<cms:pages masterpage='users/index.php' id=id >
<cms:set my_user_name = k_page_title />
<cms:reverse_related_pages 'users' masterpage='users/nor/outbox-employee.php' >
<cms:show my_user_name />
<cms:show k_page_title />
..
</cms:reverse_related_pages>
</cms:pages
An now you should be able to display values from both the blocks without the immer overriding the outer as the names are different.
Hope it helps.