Problems, need help? Have a tip or advice? Post it here.
3 posts Page 1 of 1
Hey!

I've been happy using repeatable regions, thus far, but encountered few problems. I looked through forums very hard, and didn't find any solution.

What I need:

1. Having "repeatable region editing part" in globals.php (namely list of people);
List with 6 variables - name, job_desc_en, job_desc_lv, job_desc_ru, phone, email;

2. Populating it to 3 different other templates (multilingual) and using cms:if, showing only 4 variables;
en/contact.php; lv/kontakti.php; ru/kontakty.php;

3. Showing them off!

So my question is - how do you make them repeatable regions global?

Well, I could actually use like 3 repeatable regions over all pages, and probably will - because it's easy and I only have to fill like 10-14 fields for each one, but given the fact, if I had to list like 1000+ people, would there be a solution? Just wondering.

Thanks ahead.
Hi,

The procedure of using repeatable_regions as global variables is no different from other editable regions.

For example, suppose your 'globals.php' had an editable region of type 'text' (say named 'my_text'), we can display its value on any other template like this -
Code: Select all
<cms:pages masterpage='globals.php'>
   <cms:show my_text />
</cms:pages>

Repeatable region can be displayed in a similar fashion -
Code: Select all
<cms:pages masterpage='globals.php'>
    <cms:show_repeatable 'my_repeatable'>
        <cms:show name />: <cms:show phone /> <br />
    </cms:show_repeatable>
</cms:pages>

Hope this helps.
Thank you!

Always assumed cms:pages tag was related to cloned pages, well - you always learn.
Quick and easy input, great solution.

Worked out great.
3 posts Page 1 of 1
cron