cvs: phpweb / books.php

From: Date: Thu, 15 May 2003 22:53:04 +0000
Subject: cvs: phpweb / books.php
Groups: php.mirrors 
Request: Send a blank email to php-mirrors+get-17724@lists.php.net to get a copy of this message
jacques Thu May 15 18:53:04 2003 EDT Modified files: /phpweb books.php Log: * Fix for the many <a href="Array"> where there are authorlinks. * Fixed all other E_NOTICE warnings. --jm Index: phpweb/books.php diff -u phpweb/books.php:1.186 phpweb/books.php:1.187 --- phpweb/books.php:1.186 Thu May 15 13:39:36 2003 +++ phpweb/books.php Thu May 15 18:53:04 2003 @@ -40,6 +40,9 @@ } $last = array_pop($temp); $author = join(', ', $temp) . ' &amp; ' . $last; + } else { + if ($author_link) + $author = make_link ($author_link, $author); } echo '<tr><td colspan="2">' . hdelim() . "</td></tr>\n"; @@ -49,12 +52,7 @@ print_link ($title_link, make_image ("books/".$image, $img_title, false, false, false, 0) ); echo "<br>\n</td><td><p>\n"; echo "$title\nby "; - - if ($author_link) { - print_link ($author_link, $author); - } else { - echo $author; - } + echo $author; echo "</p>\n<small>\n"; if ($info || $lang != "en") { @@ -84,9 +82,11 @@ echo '<h1>PHP Books</h1>'; // If invalid type || lang specified, unset it -list($type, $lang) = explode("_", $type_lang); -if (!isset($book_types[$type])) { unset($type); } -if (!isset($book_langs[$lang])) { unset($lang); } +if (isset($type_lang) && !empty($type_lang)) { + list($type, $lang) = explode("_", $type_lang); + if (!isset($book_types[$type])) { unset($type); } + if (!isset($book_langs[$lang])) { unset($lang); } +} // If type is set, we are printing books if (isset($type)) { ?> @@ -189,4 +189,6 @@ echo "</p>"; commonFooter(); + +/* vim: set noet ts=4 sw=4 ft=php: : */ ?>

« previous php.mirrors (#17724) next »