Mostly working :) ~900mb to ~90mb

This commit is contained in:
Kai Hendry
2015-10-01 22:39:23 +08:00
parent b00e31138f
commit 574955249b
2 changed files with 6 additions and 7 deletions

View File

@@ -10,7 +10,7 @@ $QUERY=escapeshellarg($_GET['q']);
//fwrite($fp, $_GET['q'] . " : " . $QUERY . "\n");
//fclose($fp);
exec("zgrep -Fhi $QUERY tweets.txt", $array);
exec("gunzip -c tweets.txt | grep -Fhi $QUERY", $array);
$data = json_encode($array);
echo $_GET['jsoncallback'] . '(' . $data . ');';
?>