Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strip HTML tags from title #25

Merged
merged 2 commits into from
Feb 2, 2016

Conversation

sashw
Copy link
Contributor

@sashw sashw commented Jan 31, 2016

Remove HTML tags from the page title.
This happens for example if Typogrify is activated and the title contains something like PHP. Looks ugly and especially breaks the design in mobile mode.

(cherry picked from commit 7931442)
Signed-off-by: Sascha Wagner <sascha.wagner.89@gmail.com>
@alexandrevicenzi
Copy link
Owner

I think this should be done to JSON-LD too.

I'm just wondering why someone would put html tag on titles. 😁

(cherry picked from commit 0bb7452)
Signed-off-by: Sascha Wagner <sascha.wagner.89@gmail.com>
@sashw
Copy link
Contributor Author

sashw commented Feb 2, 2016

You're right, I included it.

I wouldn't put tags in the title, too. But if you enabled Typogrify in your config it automatically puts uppercase words in <span class="caps"> which happens in the title as well. And maybe someone might put an <br> in the title to force a line break at a certain position.

alexandrevicenzi added a commit that referenced this pull request Feb 2, 2016
@alexandrevicenzi alexandrevicenzi merged commit 055ddc8 into alexandrevicenzi:master Feb 2, 2016
@alexandrevicenzi
Copy link
Owner

@sashw Thanks.

@alexandrevicenzi alexandrevicenzi added this to the 1.2 milestone Feb 2, 2016
@sashw sashw deleted the sanitize_title branch February 2, 2016 19:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants