mirror of
https://github.com/hnhx/librex.git
synced 2025-01-26 18:53:05 -03:00
10 lines
396 B
PHP
10 lines
396 B
PHP
<?php
|
|
$config = require "config.php";
|
|
require "engines/google/suggestions.php";
|
|
|
|
header('Content-Type: application/x-suggestions+json');
|
|
header('Content-Disposition: attachment; filename="suggestions.json"');
|
|
|
|
$q = isset($_REQUEST['q']) ? htmlspecialchars(trim($_REQUEST["q"])) : '';
|
|
$result = get_suggestions_results($q);
|
|
echo print_suggestions_results($result, $q);
|