Skip to content
Permalink
Browse files

sort search by click on rowtitel updates #865 updates #753

  • Loading branch information...
Slini11 committed Jan 21, 2016
1 parent 7da0a2a commit d87ec10e7118becfc14a4b5d5d1db4b74da6e7ff
@@ -1458,7 +1458,7 @@ INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('547', 'Choose l
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('548', 'HTML-Code:', '2010-08-28 11:48:04');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('549', 'Text displayed:', '2010-08-28 11:48:04');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('550', 'Text contains invalid charecters!', '2010-08-28 11:48:04');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('551', 'Alternavite logos (partly outdated):', '2015-11-24 22:36:00');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('551', 'Available logos:', '2015-11-24 22:36:00');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('552', 'Cancel', '2010-08-28 11:48:04');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('553', 'Save', '2010-08-28 11:48:04');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('554', 'The following settings are stored for your logo:', '2010-08-28 11:48:04');
@@ -2806,7 +2806,8 @@ INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2520', 'Show in
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2521', 'This table contains some false positives. References from the \"libse\" code (personal cache notes, additional waypoints) are not detected, as well as textes which are passed by variable to translation functions and multiline texts. \"Help\", \"Forum\", \"Teamblog\" and \"Informations\" are referenced in local configuration files. So be very careful before deleting anything.', '2013-11-03 10:09:14');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2522', 'OConly', '2013-11-03 10:09:14');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2523', 'Official OC logos (up-to-date):', '2015-11-24 23:30:00');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2524', 'Stored querie', '2015-01-20 20:37:00');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2524', 'Stored query', '2015-01-20 20:37:00');
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('2525', 'Alternavite logos (partly outdated):', '2015-11-24 22:36:00');

-- Table sys_trans_ref
SET NAMES 'utf8';
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('548', 'DE', 'HTML-Code:', '2010-08-28 11:48:06');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('549', 'DE', 'Angezeigter Text:', '2010-08-28 11:48:06');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('550', 'DE', 'Ungültige Zeichen im Text!', '2010-08-28 11:48:06');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('551', 'DE', 'Alternative Logos (teilweise veraltet):', '2015-11-24 22:36:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('551', 'DE', 'Verfügbare Logos:', '2015-11-24 22:36:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('552', 'DE', 'Abbrechen', '2010-08-28 11:48:06');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('553', 'DE', 'Speichern', '2010-08-28 11:48:06');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('554', 'DE', 'Folgende Einstellungen sind für dein Statistikbild gespeichert:', '2010-08-28 11:48:06');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2522', 'DE', 'OConly', '2013-11-03 10:09:14');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2523', 'DE', 'Offizielle OC logos (up-to-date):', '2015-11-24 23:30:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2524', 'DE', 'Gespeicherte Suche', '2015-01-20 20:37:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2525', 'DE', 'Alternative Logos (teilweise veraltet):', '2015-11-24 22:36:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1', 'EN', 'Reorder IDs', '2010-09-02 00:15:30');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2', 'EN', 'The database could not be reconnected.', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('3', 'EN', 'Testing – please do not login', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('548', 'EN', 'HTML code:', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('549', 'EN', 'Text displayed:', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('550', 'EN', 'Text contains invalid characters!', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('551', 'EN', 'Alternavite logos (partly outdated):', '2015-11-24 22:36:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('551', 'EN', 'Available logos:', '2015-11-24 22:36:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('552', 'EN', 'Cancel', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('553', 'EN', 'Save', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('554', 'EN', 'The following settings are stored for your logo:', '2010-08-28 11:48:07');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2392', 'EN', 'Zürich', '2013-11-03 10:09:14');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2522', 'EN', 'OConly', '2013-11-03 10:09:14');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2523', 'EN', 'Official OC logos (up-to-date):', '2015-11-24 23:30:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2524', 'EN', 'Stored querie', '2015-01-20 20:37:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2524', 'EN', 'Stored query', '2015-01-20 20:37:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2525', 'EN', 'Alternavite logos (partly outdated):', '2015-11-24 22:36:00');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('2', 'ES', 'La base de datos no se pudo conectar.', '2010-12-09 00:17:55');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('3', 'ES', 'En pruebas - por favor, no entre.', '2010-12-09 00:17:55');
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('4', 'ES', 'Usuario', '2010-12-09 00:17:55');
@@ -129,7 +129,7 @@
else
$oldDescMode = $descMode;
$short_desc = strip_tags($_POST['short_desc']); // Ocprop
$short_desc = htmlspecialchars($_POST['short_desc']); // Ocprop
$hint = htmlspecialchars($_POST['hints'], ENT_COMPAT, 'UTF-8');
$desclang = $_POST['desclang'];
$show_all_langs = isset($_POST['show_all_langs_value']) ? $_POST['show_all_langs_value'] : 0;
@@ -89,7 +89,7 @@ function search_output()
WHERE `cache_logs`.`cache_id`='" . sql_escape($rCache['cache_id']) . "'
AND `log_types`.`id`=`cache_logs`.`type`" . $ownlogs . "
ORDER BY `cache_logs`.`date` DESC, `cache_logs`.`date_created` DESC
LIMIT 5";
LIMIT 6";
$rs = sql_slave($sql);
$rCache['logs'] = sql_fetch_assoc_table($rs);
$rCache['firstlog'] = array_shift($rCache['logs']);
@@ -186,16 +186,13 @@
}
// overwrite variable options for sort direction & sort type
if (isset($_REQUEST['sortby'])){
$options['sort'] = $_REQUEST['sortby'];
$saveopt = serialize($options);
sql("UPDATE queries SET `options`='&1' WHERE `id`='&2'", $saveopt, $options['queryid']);
}
if (isset($_REQUEST['sortorder'])){
$options['sortorder'] = $_REQUEST['sortorder'];
$saveopt = serialize($options);
sql("UPDATE queries SET `options`='&1' WHERE `id`='&2'", $saveopt, $options['queryid']);
}
//check if user searched "bycreated" first --> display "bycreated"
@@ -1327,10 +1324,10 @@
{
$sql .= '`lastLog`';
if(isset($options['sortorder'])&&$options['sortorder']=='ASC'){
$sql .= ' ASC, ';
$sql .= ' ASC, `caches`.`date_created` DESC,';
}
else{
$sql .= ' DESC, ';
$sql .= ' DESC, `caches`.`date_created` DESC,';
}
$sortby = 'bydistance';
}
@@ -23,7 +23,7 @@
{/if}
<td class="{$listcolor}" valign="top"><nobr>
{if $cache.firstlog}
<nobr><a href="viewcache.php?cacheid={$cache.cache_id}&log=A#log{$cache.firstlog.id}">{include file="res_logtype.tpl" type=$cache.firstlog.type}</a>&nbsp;<a href="viewcache.php?cacheid={$cache.cache_id}&log=A#log{$cache.firstlog.id}">{$cache.firstlog.date|date_format:$opt.format.date}</a>&nbsp;&nbsp;&nbsp;&nbsp;</nobr>
<nobr><a href="viewcache.php?cacheid={$cache.cache_id}&log=A#log{$cache.firstlog.id}">{include file="res_logtype.tpl" type=$cache.firstlog.type}</a>&nbsp;<a href="viewcache.php?cacheid={$cache.cache_id}&log=A#log{$cache.firstlog.id}">{$cache.firstlog.date|date_format:$opt.format.date}</a>&nbsp;&nbsp;&nbsp;</nobr>
{else}
<img src="resource2/{$opt.template.style}/images/log/16x16-none.png" width="16" height="16" />&nbsp;--.--.----&nbsp;
{/if}
@@ -50,10 +50,10 @@
{foreach from=$cache.desclangs item=desclang}
<a href="viewcache.php?cacheid={$cache.cache_id}&desclang={$desclang|escape}" style="text-decoration:none"><b><span style="color:blue">{$desclang|escape}</span></b></a>
{/foreach}
{$cache.short_desc} &nbsp;</p>
{$cache.short_desc|escape} &nbsp;</p>
</td>
{if $sbycreated}
<td class="{$listcolor}" valign="top">{if $cache.oconly}<img src="resource2/ocstyle/images/misc/15x15-oc.png"/>{/if}&nbsp;</td>
{/if}
<td class="{$listcolor}" valign="top"><nobr>{foreach from=$cache.logs item=log}<a href="viewcache.php?cacheid={$cache.cache_id}&log=A#log{$log.id}">{include file="res_logtype.tpl" type=$log.type}</a>&nbsp;{/foreach}&nbsp;&nbsp;&nbsp;</nobr></td>
<td class="{$listcolor}" valign="top"><nobr>{foreach from=$cache.logs item=log}<a href="viewcache.php?cacheid={$cache.cache_id}&log=A#log{$log.id}">{include file="res_logtype.tpl" type=$log.type}</a>&nbsp;{/foreach}&nbsp;&nbsp;</nobr></td>
</tr>
@@ -14,7 +14,7 @@
<p style="margin-top:0.5em; padding-left:10px; padding-right:8px">
{if $userid}
<img src="resource2/ocstyle/images/misc/32x32-search.png" width="16px" height="16px" />
<a class="systemlink" href="query.php">{t}Stored querie{/t}</a> <b>{$query_name|escape}</b> {* TODO: Translation Stored querie *}
<a class="systemlink" href="query.php">{t}Stored query{/t}</a> <b>{$query_name|escape}</b>
{/if}
{if $cachelist}
<img src="resource2/ocstyle/images/misc/16x16-list.png" />
@@ -140,11 +140,11 @@
{if $sbycreated}
{if $bycreated}
<a href="search.php?queryid={$queryid}&showresult=1&sortby=bycreated&sortorder=DESC{if $startat}&startat={$startat}{/if}{if $sbycreated}&bycreated=true{/if}">
{else}<a href="search.php?queryid={$queryid}&showresult=1&sortby=bycreated&sortorder=ASC&bycreated=true{if $startat}&startat={$startat}{/if}{if $sbycreated}&bycreated=true{/if}">
{else}<a href="search.php?queryid={$queryid}&showresult=1&sortby=bycreated&sortorder=ASC{if $startat}&startat={$startat}{/if}{if $sbycreated}&bycreated=true{/if}">
{/if}
{t}Listed since{/t}
{if $sortby=='bycreated'}
{if $sortorder=='DESC'||$sortorder==""}&#x25B2;{else}&#x25BC;{/if}
{if $sortorder=='DESC'||$sortorder==''}&#x25B2;{else}&#x25BC;{/if}
{/if}</a>
{else}
&nbsp;
@@ -158,7 +158,7 @@
{/if}
{t}Own logs{/t}
{if $sortby=='bymylastlog'}
{if $sortorder=='DESC'}&#x25B2;{else}&#x25BC;{/if}
{if $sortorder=='DESC'||$sortorder==''}&#x25B2;{else}&#x25BC;{/if}
{/if}</a>
{else}
{if $bylastlog}
@@ -167,7 +167,7 @@
{/if}
{t}Last logs{/t}
{if $sortby=='bylastlog'}
{if $sortorder=='DESC'}&#x25B2;{else}&#x25BC;{/if}
{if $sortorder=='DESC'||$sortorder==''}&#x25B2;{else}&#x25BC;{/if}
{/if}</a>
{/if}
</th>

0 comments on commit d87ec10

Please sign in to comment.
You can’t perform that action at this time.