Hopefully full handling of & in everything...

This commit is contained in:
Sébastien Lucas 2012-06-18 14:12:12 +02:00
parent f7b72ec441
commit 875a776dc1
2 changed files with 6 additions and 6 deletions

View file

@ -30,7 +30,7 @@ $serie = $book->getSerie ();
foreach ($authors as $author) { foreach ($authors as $author) {
if ($i > 0) echo ", "; if ($i > 0) echo ", ";
?> ?>
<a href="index.php<?php echo str_replace ("&", "&amp;", $author->getUri ()) ?>"><?php echo $author->name ?></a> <a href="index.php<?php echo str_replace ("&", "&amp;", $author->getUri ()) ?>"><?php echo htmlspecialchars ($author->name) ?></a>
<?php <?php
} }
?> ?>
@ -44,7 +44,7 @@ $serie = $book->getSerie ();
foreach ($tags as $tag) { foreach ($tags as $tag) {
if ($i > 0) echo ", "; if ($i > 0) echo ", ";
?> ?>
<a href="index.php<?php echo str_replace ("&", "&amp;", $tag->getUri ()) ?>"><?php echo $tag->name ?></a> <a href="index.php<?php echo str_replace ("&", "&amp;", $tag->getUri ()) ?>"><?php echo htmlspecialchars ($tag->name) ?></a>
<?php <?php
} }
?> ?>
@ -58,7 +58,7 @@ $serie = $book->getSerie ();
<div class="buttonEffect pad6"> <div class="buttonEffect pad6">
<a href="index.php<?php echo str_replace ("&", "&amp;", $serie->getUri ()) ?>"><?php echo localize("series.title") ?></a> <a href="index.php<?php echo str_replace ("&", "&amp;", $serie->getUri ()) ?>"><?php echo localize("series.title") ?></a>
</div> </div>
<?php echo str_format (localize ("content.series.data"), $book->seriesIndex, $serie->name) ?> <?php echo str_format (localize ("content.series.data"), $book->seriesIndex, htmlspecialchars ($serie->name)) ?>
</div> </div>
<?php <?php
} }

View file

@ -152,13 +152,13 @@
<div class="bookdetail"> <div class="bookdetail">
<a class="navigation" href="bookdetail.php?id=<?php echo $entry->book->id ?>" /> <a class="navigation" href="bookdetail.php?id=<?php echo $entry->book->id ?>" />
<div class="entryTitle"><?php echo htmlspecialchars ($entry->title) ?></div> <div class="entryTitle"><?php echo htmlspecialchars ($entry->title) ?></div>
<div class="entryContent"><?php echo localize("authors.title") . " : " . $entry->book->getAuthorsName () ?></div> <div class="entryContent"><?php echo localize("authors.title") . " : " . htmlspecialchars ($entry->book->getAuthorsName ()) ?></div>
<div class="entryContent"><?php echo localize("tags.title") . " : " . htmlentities ($entry->book->getTagsName ()) ?></div> <div class="entryContent"><?php echo localize("tags.title") . " : " . htmlspecialchars ($entry->book->getTagsName ()) ?></div>
<?php <?php
$serie = $entry->book->getSerie (); $serie = $entry->book->getSerie ();
if (!is_null ($serie)) { if (!is_null ($serie)) {
?> ?>
<div class="entryContent"><?php echo localize("series.title") . " : " . $serie->name . " (" . $entry->book->seriesIndex . ")" ?></div> <div class="entryContent"><?php echo localize("series.title") . " : " . htmlspecialchars ($serie->name) . " (" . $entry->book->seriesIndex . ")" ?></div>
<?php <?php
} }
?> ?>