diff --git a/bibtexbrowser.php b/bibtexbrowser.php index 34fa7b5..04b3cf4 100755 --- a/bibtexbrowser.php +++ b/bibtexbrowser.php @@ -1,20 +1,30 @@ -db->search($to_find); - $header = 'Search: ' . trim($to_find); - $result = new ResultDisplay($searched, $header,array(Q_SEARCH => $to_find)); + if (count($searched)==1) $result = new SingleResultDisplay($searched[0]); + else { + $header = 'Search: ' . trim($to_find); + $result = new ResultDisplay($searched, $header,array(Q_SEARCH => $to_find)); + } // clicking an author, a menu item from the authors menu? } else if (isset($_GET[Q_AUTHOR])) { $to_find = urldecode($_GET[Q_AUTHOR]); @@ -1222,4 +1236,4 @@ else { } } ?> - \ No newline at end of file +