aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/output.php
diff options
context:
space:
mode:
authorSteve Clay <steve@mrclay.org>2013-03-31 21:09:07 -0400
committerSteve Clay <steve@mrclay.org>2013-03-31 21:09:07 -0400
commit5ccc0540fd28cc1620ffca10e3aed92319e78794 (patch)
tree9f63ec4480036bdc988b66aaf479f9978c74dbe8 /engine/lib/output.php
parent835c7fe5eb77343081b9bd33ec465f9ce8929570 (diff)
downloadelgg-5ccc0540fd28cc1620ffca10e3aed92319e78794.tar.gz
elgg-5ccc0540fd28cc1620ffca10e3aed92319e78794.tar.bz2
Fixes #4972: More robust friendly titles implementation
Diffstat (limited to 'engine/lib/output.php')
-rw-r--r--engine/lib/output.php8
1 files changed, 3 insertions, 5 deletions
diff --git a/engine/lib/output.php b/engine/lib/output.php
index da8e1ab86..c5a04989b 100644
--- a/engine/lib/output.php
+++ b/engine/lib/output.php
@@ -284,11 +284,9 @@ function elgg_get_friendly_title($title) {
return $result;
}
- // handle some special cases
- $title = str_replace('&amp;', 'and', $title);
- // quotes and angle brackets stored in the database as html encoded
- $title = htmlspecialchars_decode($title);
-
+ // titles are often stored HTML encoded
+ $title = html_entity_decode($title, ENT_QUOTES, 'UTF-8');
+
$title = ElggTranslit::urlize($title);
return $title;