All add-ons currently require PHP 7.4 or greater.

On July 4th 2024 PHP 8.2 will be the new minimum requirement for all add-ons. Expect any add-on released after that date to require 8.2 or greater. Some releases may not immediately take advantage of 8.x specific features in PHP, which means you might, be able to continue using new releases in PHP 7.4, however, if you experience an error the first thing you should do is update to PHP 8.2 then create a support ticket if the error persists.

Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Category Heading Problem

Status Resolved
Add-on / Version Publisher 1.7.4
Severity
EE Version 2.11.5

Verve -Webdesign und Grafik

Feb 02, 2017

Hi

I am trying to do this and it is not working. Means it shows just a blank {cat_name} on the page.

{exp:publisher:translate_category cat_id="{category_id}"}{cat_name}{/exp:publisher:translate_category}

When I replace the {category_id} by a number (1,2,..) it works well and shows me the categoryname.

Thanks
Res

 

#1

BoldMinded (Brian)

From other ticket:

This code gives me just {cat_name} as output on the template: {exp:publisher:translate_category cat_id=”{category_id}”}{cat_name}{/exp:publisher:translate_category} When i replace the {category_id} by the number of the category it works well.

#2

BoldMinded (Brian)

What is the tag that wraps {exp:publisher:translate_category cat_id=”{category_id}”}{cat_name}{/exp:publisher:translate_category}

#3

Verve -Webdesign und Grafik

I tried several versions. The one I sent you before was with no wrapping tag.

This one works for the default lang (DE - ID2) and shows nothing in EN

{exp:channel:category_heading channel="angebot"}
    {exp:publisher:translate_category cat_id="{category_id}"}{cat_name}{/exp:publisher:translate_category}
   {/exp:channel:category_heading}
#4

BoldMinded (Brian)

You shouldn’t need to use the translate_category tag inside of category_heading. This should translate just fine:

{exp:channel:category_heading channel=”angebot”} {category_name} {/exp:channel:category_heading}

#5

Verve -Webdesign und Grafik

Hmm, I had this first but it shows only the default lang (DE) and not the EN.

So I tried around and thought to solve it with your translate_category tags

#6

BoldMinded (Brian)

Just checking… have the categories been translated inside the Publisher module?

#7

Verve -Webdesign und Grafik

Yes, all of them.

#8

BoldMinded (Brian)

Find the libraries/Publisher_channel_categories.php file and go to line 535, then comment out the conditional.

https://www.dropbox.com/s/5n2o88u6vw2c3tz/Screenshot 2017-02-05 14.11.33.png?dl=0

See if that works for you.

#9

Verve -Webdesign und Grafik

Yes, this is it - works well now.

Thanks a lot. Res

#10

BoldMinded (Brian)

Good to hear. This will be in the next release.

Login to reply