mirror of
https://github.com/e107inc/e107.git
synced 2025-01-17 12:48:24 +01:00
Issue #1281 Include og:image meta for Page-Body content.
This commit is contained in:
parent
21fdea06d4
commit
0182c92517
@ -2106,9 +2106,7 @@ class e_parse extends e_parser
|
||||
$replace = array("'", '$', "'", '$', SITEURL, "href='".SITEURL."request.php", '', '' );
|
||||
$text = str_replace($search, $replace, $text);
|
||||
|
||||
// Fix any left-over '&'
|
||||
$text = str_replace('&', '&', $text); //first revert any previously converted.
|
||||
$text = str_replace('&', '&', $text);
|
||||
$text = $this->ampEncode($text);
|
||||
|
||||
if($tags == true && ($text))
|
||||
{
|
||||
@ -2119,6 +2117,21 @@ class e_parse extends e_parser
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Clean and Encode Ampersands '&' for output to browser.
|
||||
* @param string $text
|
||||
* @return mixed|string
|
||||
*/
|
||||
function ampEncode($text='')
|
||||
{
|
||||
// Fix any left-over '&'
|
||||
$text = str_replace('&', '&', $text); //first revert any previously converted.
|
||||
$text = str_replace('&', '&', $text);
|
||||
|
||||
return $text;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Convert any string back to plain text.
|
||||
* @param $text
|
||||
|
Loading…
x
Reference in New Issue
Block a user