Added subtypes to items and results.
This commit is contained in:
@ -138,8 +138,8 @@ INNER JOIN
|
||||
books_custom_column_2_link
|
||||
ON books_custom_column_2_link.book = books.id
|
||||
INNER JOIN
|
||||
custom_column_2 ON
|
||||
custom_column_2.id = books_custom_column_2_link.value
|
||||
custom_column_2
|
||||
ON custom_column_2.id = books_custom_column_2_link.value
|
||||
WHERE
|
||||
books.id = '$ItemID'");
|
||||
|
||||
@ -147,7 +147,22 @@ while ($row = $publisher_location->fetchArray()) {
|
||||
$row_publocation = $row['publoc'];
|
||||
}
|
||||
|
||||
// ---------- Pull subtype information ----------
|
||||
|
||||
$subtype = $db->query("SELECT custom_column_3.value AS subtype
|
||||
FROM books
|
||||
INNER JOIN
|
||||
books_custom_column_3_link
|
||||
ON books_custom_column_3_link.book = books.id
|
||||
INNER JOIN
|
||||
custom_column_3
|
||||
ON custom_column_3.id = books_custom_column_3_link.value
|
||||
WHERE
|
||||
books.id = '$ItemID'");
|
||||
|
||||
while ($row = $subtype->fetchArray()) {
|
||||
$row_subtype = $row['subtype'];
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -369,6 +384,7 @@ while ($row = $publisher_location->fetchArray()) {
|
||||
echo '<strong>Location:</strong> '.$row_publocation.'<br />';
|
||||
echo '<strong>Date: </strong>'.$row_pubdate.'<br />';
|
||||
echo '<strong>Type: </strong> <a href="results.php?ty='.$row_type.'">'.$row_type.'</a><br />';
|
||||
echo '<strong>Subtype: </strong> <a href="results.php?st='.$row_subtype.'">'.$row_subtype.'</a><br />';
|
||||
echo '<strong>Subjects: </strong>';
|
||||
while ($row = $tags->fetchArray()) {
|
||||
$row_tags = $row['name'];
|
||||
|
Reference in New Issue
Block a user