cvs: phd /themes/php phpdotnet.php
| From: | Hannes Magnusson | Date: | Sun, 30 Sep 2007 15:43:17 +0000 |
| Subject: | cvs: phd /themes/php phpdotnet.php | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-109@lists.php.net to get a copy of this message | ||
bjori Sun Sep 30 15:43:17 2007 UTC
Modified files:
/phd/themes/php phpdotnet.php
Log:
Escape the output of node->textContent (Philip)
http://cvs.php.net/viewvc.cgi/phd/themes/php/phpdotnet.php?r1=1.17&r2=1.18&diff_format=u
Index: phd/themes/php/phpdotnet.php
diff -u phd/themes/php/phpdotnet.php:1.17 phd/themes/php/phpdotnet.php:1.18
--- phd/themes/php/phpdotnet.php:1.17 Sun Sep 30 15:23:40 2007
+++ phd/themes/php/phpdotnet.php Sun Sep 30 15:43:17 2007
@@ -1,5 +1,5 @@
<?php
-/* $Id: phpdotnet.php,v 1.17 2007/09/30 15:23:40 bjori Exp $ */
+/* $Id: phpdotnet.php,v 1.18 2007/09/30 15:43:17 bjori Exp $ */
class phpdotnet extends PhDHelper {
protected $elementmap = array(
@@ -350,7 +350,7 @@
$ret = '<div class="qandaset"><ol
class="qandaset_questions">';
$i = 0;
foreach($nlist as $node) {
- $ret .= sprintf('<li><a
href="#%s">%s</a></li>', $this->tmp["qandaentry"][$i++],
$node->textContent);
+ $ret .= sprintf('<li><a
href="#%s">%s</a></li>', $this->tmp["qandaentry"][$i++],
htmlspecialchars($node->textContent,ENT_QUOTES, "UTF-8"));
}
return $ret.'</ul>'.$xml.'</div>';