summaryrefslogtreecommitdiff
path: root/search.php
diff options
context:
space:
mode:
authorFbenas <philbeansburton@gmail.com>2015-12-05 19:53:57 +0000
committerFbenas <philbeansburton@gmail.com>2015-12-05 19:53:57 +0000
commit612c2caeed437709d7af74dfd5efe3178dfe9ae4 (patch)
tree94f4b97eb56932186a26ce2386279fb72107deae /search.php
parent56380864115d6df864edf80e43492bf890a75521 (diff)
Removed multiline output.
Diffstat (limited to 'search.php')
-rw-r--r--search.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/search.php b/search.php
index 370c25e..c4db438 100644
--- a/search.php
+++ b/search.php
@@ -76,7 +76,7 @@ try {
}
// Return results
- $out = "";
+ $out = [];
if (empty($results)) {
echo "No results found\n";
} else {
@@ -93,15 +93,15 @@ try {
$i++;
continue;
}
- $out .= $result . "\n";
+ $out[] = $result;
$i++;
}
if ($count > 3) {
- $out .= " - results (" . $count . ")\n";
+ $out[] = "results (" . $count . ")";
}
}
- echo $out;
+ echo implode(" - ", $out);
} catch (Exception $e) {
echo $e->getMessage() . "\n";die();