Fix bad ID loading

This commit is contained in:
Némunaire 2012-05-24 16:03:32 +02:00
parent e0e294e784
commit f8b1fbbd82
2 changed files with 3 additions and 4 deletions

View File

@ -14,7 +14,7 @@ class Question
{ {
if (isset($node)) if (isset($node))
{ {
$this->id = $node->getAttribute("id"); $this->id = $node->getAttribute("xml:id");
$this->added_time = $node->getAttribute("addedtime"); $this->added_time = $node->getAttribute("addedtime");
if (intval($node->getAttribute("validated"))) if (intval($node->getAttribute("validated")))
$this->validated = true; $this->validated = true;

View File

@ -17,7 +17,7 @@ if (!$question)
else else
{ {
$dest_mail = $question->get_validator(); $dest_mail = $question->get_validator();
$validationAddress = "validation.php?id="; $validationAddress = "validation.php?id=".$question->getId();
// Uncomment the following part for random email // Uncomment the following part for random email
/* /*
@ -49,8 +49,7 @@ else
."Adresse de confirmation de la question:\n" ."Adresse de confirmation de la question:\n"
. "http://".$_SERVER["SERVER_NAME"] . "http://".$_SERVER["SERVER_NAME"]
. dirname($_SERVER["REQUEST_URI"])."/validation.php?id=" . dirname($_SERVER["REQUEST_URI"]) . $validationAddress
. $question->getId()
. "\n\n Merci beaucoup de votre participation\n" . "\n\n Merci beaucoup de votre participation\n"