Forum
Categories title to ignore HTMl in backend
Hi Guys,
Not sure if this is a bug, an oversight or if I am not doing something 'right'. But I have created some categories. For the front-end I need to display these with specific line breaks in between certain words for visual presentation. So I added html="true" to the catTitle field and added <br>'s as I needed them. The problem is that this is used within the backed, so the title contains a line break, which looks a little odd. See here; https://cl.ly/image/3h3Q3p0S3N3E
Just thought I would mention it as I saw it. perhaps the CatTitle needs to strip html tags for the backend?
There are going to be instances within my code where I will need the catTitle without the <br> - I was going to use the striptags="true" command on those template items. But do you think there is a better to approach this whole solution?
Cheers Terry
Also notice it uses them here too... https://cl.ly/image/083N0z1b1M40
The correct behaviour is that Perch should be encoding the markup. The title case is incorrect.
Hi Drew. What was the outcome of this thread? Did you mean it was a bug and shouldn't output the HTML in the backed?
Thanks Terry
The case where the
<br>
is treated as HTML is a bug.Thanks Drew. Will this be fixed in a future update?
Yes, it's been fixed.
I still see it in 2.7.3. So I assume it's ready for one you have not released yet?
Which part are you seeing?
This is what I am seeing still;
https://cl.ly/image/33200v2l2806
https://cl.ly/image/3f1C3c2M3K07
Great - that's correct.
Oh right, is it? Sorry. I thought it would not show the HTML at all in those fields.
Those fields don't support HTML, so it's presented as text.
Thats ok. I had assumed (perhaps incorrectly) it would just strip tags so no HTMl or HTML text was shown. It's ok though. Thanks Drew.