Multiple Categories
2 posts by 2 authors in: Forums > CMS Builder
Last Post: January 11, 2012 (RSS)
By mediaco - January 11, 2012
I have a site that has multiple categories.
I have the nav set to display in an unordered list.
On most pages (single & Multi) the 'categoryFormat' is working, showing both categories with onelevel.
But on either category pages both categories are showing as two level in the navigation.
Ideally on the specified page I want the appropriate nav(category) to show twolevel and the other nav(category) as just onelevel.
Essentially this is displays similar to a toggled menu from page to page.
Snippet of my Code ...
list($lta_practiceRecords, $selectedCategory) = getCategories(array(
'tableName' => 'lta_practice',
'selectedCategoryNum' => '', // defaults to getNumberFromEndOfUrl()
'categoryFormat' => 'twolevel', // showall, onelevel, twolevel
'useSeoUrls' => true,
));
list($resourcesRecords, $selectedCategory2) = getCategories(array(
'tableName' => 'resources',
'selectedCategoryNum' => '', // defaults to getNumberFromEndOfUrl()
'categoryFormat' => 'onelevel', // showall, onelevel, twolevel
'useSeoUrls' => true,
'limit' => '1',
));
<ul>
<?php foreach ($lta_practiceRecords as $lta_practiceRecord): ?>
<?php echo $lta_practiceRecord['_listItemStart'] ?> <a href="<?php echo $lta_practiceRecord['_link'] ?>"><?php echo $lta_practiceRecord['name'] ?></a> <?php echo $lta_practiceRecord['_listItemEnd'] ?>
<?php endforeach; ?>
<?php foreach ($resourcesRecords as $resourcesRecord): ?>
<?php echo $resourcesRecord['_listItemStart'] ?> <a href="<?php echo $resourcesRecord['_link'] ?>"><?php echo $resourcesRecord['name'] ?></a> <?php echo $resourcesRecord['_listItemEnd'] ?>
<?php endforeach; ?>
</ul>
It seems a problem having multiple categoryFormat with opposing values on one page?
Any help appreciated [crazy]
I have the nav set to display in an unordered list.
On most pages (single & Multi) the 'categoryFormat' is working, showing both categories with onelevel.
But on either category pages both categories are showing as two level in the navigation.
Ideally on the specified page I want the appropriate nav(category) to show twolevel and the other nav(category) as just onelevel.
Essentially this is displays similar to a toggled menu from page to page.
Snippet of my Code ...
list($lta_practiceRecords, $selectedCategory) = getCategories(array(
'tableName' => 'lta_practice',
'selectedCategoryNum' => '', // defaults to getNumberFromEndOfUrl()
'categoryFormat' => 'twolevel', // showall, onelevel, twolevel
'useSeoUrls' => true,
));
list($resourcesRecords, $selectedCategory2) = getCategories(array(
'tableName' => 'resources',
'selectedCategoryNum' => '', // defaults to getNumberFromEndOfUrl()
'categoryFormat' => 'onelevel', // showall, onelevel, twolevel
'useSeoUrls' => true,
'limit' => '1',
));
<ul>
<?php foreach ($lta_practiceRecords as $lta_practiceRecord): ?>
<?php echo $lta_practiceRecord['_listItemStart'] ?> <a href="<?php echo $lta_practiceRecord['_link'] ?>"><?php echo $lta_practiceRecord['name'] ?></a> <?php echo $lta_practiceRecord['_listItemEnd'] ?>
<?php endforeach; ?>
<?php foreach ($resourcesRecords as $resourcesRecord): ?>
<?php echo $resourcesRecord['_listItemStart'] ?> <a href="<?php echo $resourcesRecord['_link'] ?>"><?php echo $resourcesRecord['name'] ?></a> <?php echo $resourcesRecord['_listItemEnd'] ?>
<?php endforeach; ?>
</ul>
It seems a problem having multiple categoryFormat with opposing values on one page?
Any help appreciated [crazy]
Re: [mediaco] Multiple Categories
By Jason - January 11, 2012
Hi,
So on this page you have $lta_practiceRecords set to twolevel and $resourceRecords set to onelevel. Is the page returning something different? Could you describe what the page is producing and how it differs from what you would expect?
Let us know and we can take a closer look for you.
Thanks
So on this page you have $lta_practiceRecords set to twolevel and $resourceRecords set to onelevel. Is the page returning something different? Could you describe what the page is producing and how it differs from what you would expect?
Let us know and we can take a closer look for you.
Thanks
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/