?
avatar joris85
joris85
20 Jan 2015

Steps to reproduce the issue

If i ad a article title and i ad a span, it strips it.

Expected result

The result i want is that i can add a break or span or maybe an icon in the title.
So no html stripping or maybe allow a few things.

Does any body know the reason that this is not possible?
I think there is a reason for it though :-)

avatar joris85 joris85 - open - 20 Jan 2015
avatar rgmears
rgmears - comment - 20 Jan 2015

I agree that it would be good to be able to add HTML to titles. Especially character entities like — or —, etc.


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5830.
avatar rgmears
rgmears - comment - 20 Jan 2015

... make that — and —


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5830.
avatar brianteeman
brianteeman - comment - 20 Jan 2015

You can already use &mdash

On 20 January 2015 at 14:39, rgmears notifications@github.com wrote:

... make that — and —

This comment was created with the J!Tracker Application
https://github.com/joomla/jissues at issues.joomla.org/joomla-cms/5830
http://issues.joomla.org/tracker/joomla-cms/5830.


Reply to this email directly or view it on GitHub
#5830 (comment).

Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/

avatar rgmears
rgmears - comment - 20 Jan 2015

Great. What about · (which is for a mini-bullet · ) or • ( which is for bullet • ) ?

avatar brianteeman
brianteeman - comment - 20 Jan 2015

Have you tried it yourself? did it work?

On 20 January 2015 at 14:55, Robert G Mears notifications@github.com
wrote:

Great. What about · (which is for a mini-bullet · ) or • (
which is for bullet • ) ?


Reply to this email directly or view it on GitHub
#5830 (comment).

Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/

avatar joris85
joris85 - comment - 20 Jan 2015

Thanks for the tips! Did not know this so nice to know.
The bullet works.

But this is not wat i was looking for, i really want to use span or break in the titles

avatar rgmears
rgmears - comment - 20 Jan 2015

@brianteeman
The letters work, but not the numbers. Tried that a couple of years ago and it didn't work. Nice that it does now.

Still, I agree with @joris85 . It would be nice to be able to add TITLE for styling reasons. Although this could be done as an override in the respective file; except it would appear on all pages using that file, some where it may not be needed..

avatar rgmears
rgmears - comment - 20 Jan 2015

@joris85
You can use   (non-breaking space) to join two words if that helps. But it disappears in the title box.

avatar nternetinspired
nternetinspired - comment - 23 Jan 2015

It's safer to strip html from titles. Yes, you might only want to use a <span> but allowing any html allows the possibility that malicious code is inserted there too.

avatar rgmears
rgmears - comment - 23 Jan 2015

Is the same the case if one does an override which adds a span element inside an H1 or H2, etc?

avatar Bakual
Bakual - comment - 23 Jan 2015

There are two issues I see. One is what Seth mentioned, allowing all HTML would result in a small security risk. So we need to filter it for sure similar to what we do with the article body.
The second and imho bigger issue would be that the article title is not only used in a HTML page. It is also used to build a feed and depending on installed extensions maybe even in other enviroments. Not all of them will be happy with HTML in a title and could break.
Even if we're strictly talking about a HTML page, what looks good on the article page itself doesn't necessary look fine on the list (front- or backend), modules or wherever the title is shown as well.

avatar nternetinspired
nternetinspired - comment - 23 Jan 2015

The second and imho bigger issue would be that the article title is not only used in a HTML page. It is also used to build a feed and depending on installed extensions maybe even in other environments. Not all of them will be happy with HTML in a title and could break.

This is a very good point. You definitely don't want that in your RSS feed or <title> so you'd need to do a strip-html on everywhere but the actual page content. As it's already possible to do this stuff with plugins, like JB Type for example, I'd say that there isn't much of a case for including such functionality in core, given that 99.98% of users wouldn't ever want to do this.

avatar rdeutz
rdeutz - comment - 23 Jan 2015

Yeah, sometimes this would be nice. But there are ways to do it e.g. "--" in title will be replaced with break. I think it is very specific and to have a solution for all cases is complicated to find.

avatar joris85
joris85 - comment - 23 Jan 2015

The solution, a parameter :) allowed html characters. Or html yes or no.

avatar mbabker
mbabker - comment - 23 Jan 2015

Wouldn't work well at all. If the param is set to yes for one user but no for another, then the user who is allowed to insert HTML to the title will gripe because their HTML is being stripped by someone else. Also, we REALLY don't need anymore parameters anywhere IMO; the backend needs to go on a parameter diet. The current behavior is consistent and it works for the "normal" use cases.

avatar roland-d
roland-d - comment - 23 Jan 2015

I also think this is not something we should add into the core. As for yet another parameter, please no. There are way too many already. My suggestion is to close this PR as I don't see this going to get merged.

avatar Bakual
Bakual - comment - 23 Jan 2015

Closing per comments from 3 PLT and other valued community members

avatar Bakual Bakual - change - 23 Jan 2015
Status New Closed
Closed_Date 0000-00-00 00:00:00 2015-01-23 21:59:05
avatar Bakual Bakual - close - 23 Jan 2015
avatar zero-24 zero-24 - close - 23 Jan 2015
avatar joris85
joris85 - comment - 24 Jan 2015

why a filter per user? You can leave some resposibility to the admin right? Just filter or not. If it goes wrong you set it on filter and done.

Common even wordpress i can add spans and a much more pro cms cant. And if you put the option in core than no need for override the core for those who can use this option.

If you ask me there is really no reason to not add it to the core. Default filter and possible to add accepted characters

avatar zero-24 zero-24 - change - 7 Jul 2015
Labels Added: ?

Add a Comment

Login with GitHub to post a comment