summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorDerek Jones <derek.jones@ellislab.com>2008-09-27 02:06:19 +0200
committerDerek Jones <derek.jones@ellislab.com>2008-09-27 02:06:19 +0200
commit07fa5664978b333f6fd84f4248c50cdbdfe9dc6b (patch)
tree20710bc3d404e69a8addd46c922971e2dd3316eb /system
parentba5c4ce31b0b2cbd3a5737a8a887a906bdc80b6d (diff)
tweak of inline_element regex so that it doesn't hit partial matches, i.e. viewing <blockquote as <b
Diffstat (limited to 'system')
-rw-r--r--system/libraries/Typography.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/system/libraries/Typography.php b/system/libraries/Typography.php
index 94c9de01b..57cb97c73 100644
--- a/system/libraries/Typography.php
+++ b/system/libraries/Typography.php
@@ -101,7 +101,7 @@ class CI_Typography {
// Convert "ignore" tags to temporary marker. The parser splits out the string at every tag
// it encounters. Certain inline tags, like image tags, links, span tags, etc. will be
// adversely affected if they are split out so we'll convert the opening bracket < temporarily to: {@TAG}
- $str = preg_replace("#<(/*)(".$this->inline_elements.")#i", "{@TAG}\\1\\2", $str);
+ $str = preg_replace("#<(/*)(".$this->inline_elements.")[ >]#i", "{@TAG}\\1\\2", $str);
// Split the string at every tag. This expression creates an array with this prototype:
//
@@ -132,7 +132,7 @@ class CI_Typography {
$str .= $chunk;
continue;
}
-
+
if ($process == FALSE)
{
$str .= $chunk;