Skip to content
Snippets Groups Projects
Commit ae0dc874 authored by Olav Morken's avatar Olav Morken
Browse files

Metadata parser: Clean up output.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@1396 44740490-163a-0410-bde0-09ae8108e29a
parent 91d09950
No related branches found
No related tags found
No related merge requests found
...@@ -11,7 +11,7 @@ $this->includeAtTemplateBase('includes/header.php'); ...@@ -11,7 +11,7 @@ $this->includeAtTemplateBase('includes/header.php');
<p><?php echo($this->t('{admin:metaconv_xmlmetadata}')); ?></p> <p><?php echo($this->t('{admin:metaconv_xmlmetadata}')); ?></p>
<p> <p>
<textarea rows="20" cols="75" name="xmldata"><?php echo htmlspecialchars($this->data['xmldata']); ?></textarea> <textarea rows="20" cols="120" name="xmldata"><?php echo htmlspecialchars($this->data['xmldata']); ?></textarea>
</p> </p>
<p> <p>
<input type="submit" value="<?php echo $this->t('metaconv_parse'); ?>" /> <input type="submit" value="<?php echo $this->t('metaconv_parse'); ?>" />
...@@ -32,7 +32,7 @@ if($output !== NULL) { ...@@ -32,7 +32,7 @@ if($output !== NULL) {
} }
echo('<h3>' . htmlspecialchars($type) . '</h3>' . "\n"); echo('<h3>' . htmlspecialchars($type) . '</h3>' . "\n");
echo('<pre>' . htmlspecialchars($text) . '</pre>' . "\n"); echo('<pre class="metadatabox">' . htmlspecialchars($text) . '</pre>' . "\n");
} }
} }
......
...@@ -39,8 +39,13 @@ try { ...@@ -39,8 +39,13 @@ try {
continue; continue;
} }
$text .= '$metadata[\'' . addslashes($entityId) . '\'] = ' . /* Remove the entityDescriptor element because it is unused, and only
var_export($entityMetadata, TRUE) . ';' . "\n"; * makes the output harder to read.
*/
unset($entityMetadata['entityDescriptor']);
$text .= var_export($entityId, TRUE) . ' => ' .
var_export($entityMetadata, TRUE) . ",\n";
} }
$entities = $text; $entities = $text;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment