Файл: public_html/mp3/index.php
Строк: 34
<?php
$title = 'Поиск музыки';
include 'simple_html_dom.php';
include 'conf.php';
if(isset($_POST['only']))
{
$url = 'http://mp3.waprik.ru/index.php?query='.urlencode($_POST['query']).'&only=1&action=query&form=true';
$ok = true;
}
elseif(isset($_POST['query']))
{
$url = 'http://mp3.waprik.ru/index.php?query='.urlencode($_POST['query']).'&action=query&form=true';
$ok = true;
}
else
{
$url = 'http://mp3.waprik.ru/index.php?';
$ok = false;
}
if($ok == true)
{
$headd = get_headers($url, 1);
if (isset($headd['Location']))
{
$loc = str_replace('http://mp3.waprik.ru/', ''.HOME.'', $headd['Location']);
header('Location: '.$loc.'');
exit();
}
else
{
include 'head.php';
echo 'Ошибка';
include_once '../sys/foot.php';
}
}
else
{
include 'head.php';
echo '<div class="tdblock4b8dab">Поиск музыки</div><div class="blockan"><form action="?" method="post">
<b>Введите исполнителя или
название песни: </b><br><input name="query" type="text" />
<input name="action" type="hidden" value="query" />
<input name="form" type="hidden" value="true" />
<input value="Искать" type="submit" /></div></form>';
include_once '../sys/mc_foot.php';
}
?>