Forum
Display region to another page
I want to get a region to display on another page. But i'm getting an error "No matching content regions found. Check region name (Subpages left content) and page path options."
On my test page I have the following:
<?php
perch_content_custom('Subpages left content', array(
'skip-template' => false,
'template'=>'subpages/catlist_test.html'
));
?>
On my the other page
perch_content_create('Subpages left content', array(
'template' => 'subpages/subpages_details_left_column.html',
'multiple' => false,
'sort' => 'date',
'sort-order' => 'DESC',
'searchable' => true,
'filter' => 'slug',
'match' => 'eq',
'value' => perch_get('s'),
'count' => 1,
));
perch_content_custom('Subpages left content', array(
'skip-template' => false,
'template'=>'subpages/subpages_details_left_column.html'
));
perch_content_custom()
will retrieve regions for the current page, unless you specify that it should get them from a different page. You do that with thepage
option.