From 03b7dc6106425909dc236ebc427810756e60fd52 Mon Sep 17 00:00:00 2001 From: Kevin Montag Date: Fri, 10 Jun 2011 02:13:34 -0700 Subject: [PATCH] Use double quotes when printing XML attributes, since htmlspecialchars won't convert single quotes in the attribute values by default. --- XMPPHP/XMLObj.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/XMPPHP/XMLObj.php b/XMPPHP/XMLObj.php index 0d3e219..8570a5c 100644 --- a/XMPPHP/XMLObj.php +++ b/XMPPHP/XMLObj.php @@ -115,7 +115,7 @@ class XMPPHP_XMLObj { foreach($this->attrs as $key => $value) { if($key != 'xmlns') { $value = htmlspecialchars($value); - $str .= "$key='$value' "; + $str .= "$key=\"$value\" "; } } $str .= ">";