Page MenuHomePhabricator

ondemand-source.php
No OneTemporary

ondemand-source.php

<?php
require_once '../../support/php/JavelinHelper.php';
$query = $_GET['q'];
$list = file_get_contents('animals.txt');
$list = explode("\n", trim($list));
$response = array();
foreach ($list as $animal) {
if (strncasecmp($query, $animal, strlen($query)) == 0) {
$response[] = array(
ucfirst($animal),
'http://www.google.com/search?q='.$animal,
$animal);
}
}
echo JavelinHelper::renderAjaxResponse($response);

File Metadata

Mime Type
text/x-php
Expires
Fri, Jun 11, 10:45 AM (1 d, 23 h)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
3391409
Default Alt Text
ondemand-source.php (442 B)

Event Timeline