Show category label on page when queried in URL

6 posts by 2 authors in: Forums > CMS Builder
Last Post: October 9, 2017   (RSS)

By Mikey - October 8, 2017

Is it possible to show the label for a category queried in the URL?

"Burgers" has a category num of "16", and is selected from a field called "meal_category".

Example of a category search for meals:

http://example.com/meals.php?meal_category=16

When the meal_category=16 is queried in the URL, I'd like to show the label for the category on the on page - as seen below:

Burgers

Thanks, Zicky

Hi Zick,

What happens when you use the :label pseudo on the detail page?

Something like:

<?php echo $your_sectionRecord['meal_category:label'] ?>

Jerry Kornbluth

The first CMS Builder reference book is now available on-line!







Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php

Hey. glad it sparked a solution.

I also use a break to make sure that theere's only one category title, but forgot about that when I posted.

Jerry

BTW, got any thoughts about my ajax post?

The first CMS Builder reference book is now available on-line!







Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php

By Mikey - October 9, 2017

I'll check out your ajax post and see if there's anything I can suggest once I return from dinner.

Zicky

Thanks Zick

The first CMS Builder reference book is now available on-line!







Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php