mirror of
https://github.com/WhatCD/Gazelle.git
synced 2024-12-12 18:36:29 +00:00
Empty commit
This commit is contained in:
parent
c5e5105cca
commit
d16aef7dbf
@ -29,6 +29,9 @@ abstract protected function listener_events();
|
||||
public $Restart = 0; //Die by default
|
||||
|
||||
public function __construct() {
|
||||
if (isset($_SERVER['HOME']) && is_dir($_SERVER['HOME']) && getcwd() != $_SERVER['HOME']) {
|
||||
chdir($_SERVER['HOME']);
|
||||
}
|
||||
//ini_set('memory_limit', '12M');
|
||||
restore_error_handler(); //Avoid PHP error logging
|
||||
set_time_limit(0);
|
||||
|
@ -24,7 +24,6 @@
|
||||
case 'artists':
|
||||
?>
|
||||
<Url type="text/html" method="get" template="http<?=($SSL?'s':'')?>://<?=SITE_URL?>/artist.php?artistname={searchTerms}"></Url>
|
||||
<Url type="application/x-suggestions+json" template="http<?=($SSL?'s':'')?>://<?=SITE_URL?>/artist.php?action=autocomplete&name={searchTerms}" />
|
||||
<moz:SearchForm>http<?=($SSL?'s':'')?>://<?=SITE_URL?>/torrents.php?action=advanced</moz:SearchForm>
|
||||
<?
|
||||
break;
|
||||
|
@ -1,4 +1,7 @@
|
||||
<?
|
||||
if (empty($_GET['query'])) {
|
||||
error(0);
|
||||
}
|
||||
header('Content-Type: application/json; charset=utf-8');
|
||||
|
||||
$FullName = rawurldecode($_GET['query']);
|
||||
@ -30,10 +33,11 @@
|
||||
}
|
||||
|
||||
$Matched = 0;
|
||||
$Suggestions = array();
|
||||
$ArtistIDs = array();
|
||||
$Response = array();
|
||||
$Response['query'] = $FullName;
|
||||
$Response = array(
|
||||
'query' => $FullName,
|
||||
'suggestions' => array()
|
||||
);
|
||||
foreach ($AutoSuggest as $Suggestion) {
|
||||
list($ID, $Name) = $Suggestion;
|
||||
if (stripos($Name, $FullName) === 0) {
|
||||
|
@ -24,10 +24,11 @@
|
||||
}
|
||||
|
||||
$Matched = 0;
|
||||
$Suggestions = array();
|
||||
$ArtistIDs = array();
|
||||
$Response = array();
|
||||
$Response['query'] = $FullName;
|
||||
$Response = array(
|
||||
'query' => $FullName,
|
||||
'suggestions' => array()
|
||||
);
|
||||
foreach ($AutoSuggest as $Suggestion) {
|
||||
list($Name) = $Suggestion;
|
||||
if (stripos($Name, $FullName) === 0) {
|
||||
|
@ -5,26 +5,31 @@ $(document).ready(function() {
|
||||
var url = new URL();
|
||||
|
||||
$('#artistsearch' + SELECTOR).autocomplete({
|
||||
serviceUrl : ARTIST_AUTOCOMPLETE_URL,
|
||||
deferRequestBy: 300,
|
||||
onSelect : function(suggestion) {
|
||||
window.location = 'artist.php?id=' + suggestion['data'];
|
||||
},
|
||||
serviceUrl : ARTIST_AUTOCOMPLETE_URL,
|
||||
});
|
||||
|
||||
if (url.path == 'torrents' || url.path == 'upload' || url.path == 'artist' || (url.path == 'requests' && url.query['action'] == 'new') || url.path == 'collages') {
|
||||
$("#artist" + SELECTOR).autocomplete({
|
||||
deferRequestBy: 300,
|
||||
serviceUrl : ARTIST_AUTOCOMPLETE_URL
|
||||
});
|
||||
$("#artistsimilar" + SELECTOR).autocomplete({
|
||||
deferRequestBy: 300,
|
||||
serviceUrl : ARTIST_AUTOCOMPLETE_URL
|
||||
});
|
||||
}
|
||||
if (url.path == 'torrents' || url.path == 'upload' || url.path == 'collages' || url.path == 'requests' || url.path == 'top10' || (url.path == 'requests' && url.query['action'] == 'new')) {
|
||||
$("#tags" + SELECTOR).autocomplete({
|
||||
serviceUrl : TAGS_AUTOCOMPLETE_URL,
|
||||
delimiter: ','
|
||||
deferRequestBy: 300,
|
||||
delimiter: ',',
|
||||
serviceUrl : TAGS_AUTOCOMPLETE_URL
|
||||
});
|
||||
$("#tagname" + SELECTOR).autocomplete({
|
||||
deferRequestBy: 300,
|
||||
serviceUrl : TAGS_AUTOCOMPLETE_URL,
|
||||
});
|
||||
}
|
||||
|
@ -547,3 +547,7 @@ tr.torrent .bookmark>a:after {
|
||||
width: 250px;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.setting_description p {
|
||||
margin-top: 1em;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user