diff options
author | Olav Morken <olav.morken@uninett.no> | 2013-05-22 08:49:23 +0000 |
---|---|---|
committer | Olav Morken <olav.morken@uninett.no> | 2013-05-22 08:49:23 +0000 |
commit | 710afa6f15eeaa7c26327a888f1793b9a0f42fbd (patch) | |
tree | 60f0d657ac9802e91dbf716ffa9609d912f1c2c7 /lib/SAML2 | |
parent | 1418c5a8475abe82431226ca59adace16eb8bd21 (diff) | |
download | simplesamlphp-710afa6f15eeaa7c26327a888f1793b9a0f42fbd.zip simplesamlphp-710afa6f15eeaa7c26327a888f1793b9a0f42fbd.tar.gz simplesamlphp-710afa6f15eeaa7c26327a888f1793b9a0f42fbd.tar.bz2 |
SAML2: Fix generation of mdui:Keyword with ampersand in keyword.
Same problem as fixed in r3241.
git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@3242 44740490-163a-0410-bde0-09ae8108e29a
Diffstat (limited to 'lib/SAML2')
-rw-r--r-- | lib/SAML2/XML/mdui/Keywords.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/SAML2/XML/mdui/Keywords.php b/lib/SAML2/XML/mdui/Keywords.php index 0cc2893..161f5e9 100644 --- a/lib/SAML2/XML/mdui/Keywords.php +++ b/lib/SAML2/XML/mdui/Keywords.php @@ -63,14 +63,15 @@ class SAML2_XML_mdui_Keywords { $e = $doc->createElementNS(SAML2_XML_mdui_UIInfo::NS, 'mdui:Keywords'); $e->setAttribute('xml:lang', $this->lang); - $e->nodeValue = ''; + $value = ''; foreach ($this->Keywords as $keyword) { if (strpos($keyword, "+") !== false) { throw new Exception('Keywords may not contain a "+" character.'); } - $e->nodeValue .= str_replace(' ', '+', $keyword) . ' '; + $value .= str_replace(' ', '+', $keyword) . ' '; } - $e->nodeValue = rtrim($e->nodeValue); + $value = rtrim($value); + $e->appendChild($doc->createTextNode($value)); $parent->appendChild($e); return $e; |