EE1 plugin code/htmlentities() question
| From: | Micky Hulse | Date: | Mon, 29 Nov 2010 19:24:22 +0000 |
| Subject: | EE1 plugin code/htmlentities() question | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-309750@lists.php.net to get a copy of this message | ||
Hello,
I was looking at this ExpressionEngine plugin:
<http://expressionengine.com/downloads/details/xml_encode/>
Description: This plugin converts reserved XML characters to entities.
It is used in the RSS templates.
... Curious about this code:
trim(str_replace(array('/', ' '), array("/",
' '), $str));
The plugin author used the above bit of code in the return statement.
Just curious if their is any particular reason why one would want to
replace / and with / and   respectively?
For example, I am writing a similar plugin which utilizes
htmlentities()... I guess I am just wondering if I should apply the
same code as above to my entity-converted string?
Thoughts?
Thanks!
Micky