completed data license functions, picture fixes, public profile link
+ menu option "my profile/public profile" - enlargit log pics - short date format for some locales - data license constants * dont display license-disabled log pics * delete log pics on declined license instead replacing + delete waypoint descriptions on declined license * no cache desc replacement message if it was empty + license-content-disable-function for old-disabled users + script to process all old-deleted users due to incompatible license + settings for license admin functions and for license disclaimer - fixed CC license link on english tos page * update caches.last_modified with changes of additional waypoints + XML interface license disclaimer
This commit is contained in:
@ -106,7 +106,7 @@ function formAction()
|
||||
|
||||
function searchUser()
|
||||
{
|
||||
global $tpl;
|
||||
global $tpl, $opt;
|
||||
|
||||
$username = isset($_REQUEST['username']) ? $_REQUEST['username'] : '';
|
||||
$msg = isset($_REQUEST['msg']) ? $_REQUEST['msg'] : '';
|
||||
@ -114,7 +114,7 @@ function searchUser()
|
||||
$tpl->assign('username', $username);
|
||||
$tpl->assign('msg', $msg);
|
||||
|
||||
$rs = sql("SELECT `user_id`, `username`, `email`, `email_problems`, `date_created`, `last_modified`, `is_active_flag`, `activation_code`, `first_name`, `last_name`, `data_license`=1 AS `license_declined` FROM `user` WHERE `username`='&1' OR `email`='&1'", $username);
|
||||
$rs = sql("SELECT `user_id`, `username`, `email`, `email_problems`, `date_created`, `last_modified`, `is_active_flag`, `activation_code`, `first_name`, `last_name`, `data_license`='&2' AS `license_declined` FROM `user` WHERE `username`='&1' OR `email`='&1'", $username, NEW_DATA_LICENSE_ACTIVELY_DECLINED);
|
||||
$r = sql_fetch_assoc($rs);
|
||||
sql_free_result($rs);
|
||||
if ($r == false)
|
||||
@ -138,7 +138,8 @@ function searchUser()
|
||||
$tpl->error(ERROR_UNKNOWN);
|
||||
$tpl->assign('candisable', $user->canDisable());
|
||||
$tpl->assign('candelete', $user->canDelete());
|
||||
$tpl->assign('cansetemail', !$user->missedDataLicenseMail());
|
||||
$tpl->assign('cansetemail', !$user->missedDataLicenseMail() && $r['email'] != "");
|
||||
$tpl->assign('licensefunctions', $opt['logic']['license']['admin']);
|
||||
|
||||
$tpl->display();
|
||||
}
|
||||
|
@ -97,9 +97,12 @@
|
||||
$opt['locale']['EN']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['EN']['format']['time'] = '%I:%M %p';
|
||||
$opt['locale']['EN']['format']['timesec'] = '%X';
|
||||
$opt['locale']['EN']['format']['phpdate'] = 'm/d/Y';
|
||||
$opt['locale']['EN']['country'] = 'UK';
|
||||
$opt['locale']['EN']['page']['subtitle1'] = 'Geocaching with Opencaching';
|
||||
$opt['locale']['EN']['page']['subtitle2'] = '';
|
||||
$opt['locale']['EN']['page']['license_url'] = 'http://creativecommons.org/licenses/by-nc-nd/3.0/de/deed.en';
|
||||
$opt['locale']['EN']['page']['license'] = '<a rel="license" href="%1" target="_blank"><img alt="Creative Commons License Terms" style="border-width:0" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a><br />The www.opencaching.de content is licensed under <br /><a rel="license" href=%1" target="_blank">Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Germany</a> License.';
|
||||
|
||||
$opt['locale']['DE']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
@ -109,44 +112,50 @@
|
||||
$opt['locale']['DE']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['DE']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['DE']['format']['timesec'] = '%X';
|
||||
$opt['locale']['DE']['format']['phpdate'] = 'd.m.Y';
|
||||
$opt['locale']['DE']['country'] = 'DE';
|
||||
$opt['locale']['DE']['page']['subtitle1'] = 'Geocaching in Deutschland,';
|
||||
$opt['locale']['DE']['page']['subtitle2'] = 'Österreich und der Schweiz';
|
||||
$opt['locale']['DE']['page']['subtitle1'] = 'Geocaching mit Opencaching';
|
||||
$opt['locale']['DE']['page']['subtitle2'] = '';
|
||||
$opt['locale']['DE']['page']['license_url'] = 'http://creativecommons.org/licenses/by-nc-nd/3.0/de/';
|
||||
$opt['locale']['DE']['page']['license'] = '<a rel="license" href="%1" target="_blank"><img alt="Creative Commons Lizenzvertrag" style="border-width:0" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a><br />Der Inhalt von www.opencaching.de steht unter einer <br /><a rel="license" href="%1" target="_blank">Creative Commons Namensnennung-NichtKommerziell-KeineBearbeitung-3.0-Deutschland</a>-Lizenz.';
|
||||
$opt['locale']['DE']['helpwiki'] = "http://wiki.opencaching.de/index.php/";
|
||||
|
||||
$opt['locale']['FR']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['FR']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['FR']['format']['date'] = '%x';
|
||||
$opt['locale']['FR']['format']['datelong'] = '%d. %B %Y';
|
||||
$opt['locale']['FR']['format']['datetime'] = '%x %H:%M';
|
||||
$opt['locale']['FR']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['FR']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['FR']['format']['timesec'] = '%X';
|
||||
$opt['locale']['FR']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['FR']['country'] = 'FR';
|
||||
|
||||
$opt['locale']['PL']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['PL']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['PL']['format']['date'] = '%x';
|
||||
$opt['locale']['PL']['format']['datelong'] = '%d. %B %Y';
|
||||
$opt['locale']['PL']['format']['datetime'] = '%x %H:%M';
|
||||
$opt['locale']['PL']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['PL']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['PL']['format']['timesec'] = '%X';
|
||||
$opt['locale']['PL']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['PL']['country'] = 'PL';
|
||||
|
||||
$opt['locale']['NL']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['NL']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['NL']['format']['date'] = '%x';
|
||||
$opt['locale']['NL']['format']['datelong'] = '%d. %B %Y';
|
||||
$opt['locale']['NL']['format']['datetime'] = '%x %H:%M';
|
||||
$opt['locale']['NL']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['NL']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['NL']['format']['timesec'] = '%X';
|
||||
$opt['locale']['NL']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['NL']['page']['subtitle1'] = 'Geocaching met Opencaching';
|
||||
$opt['locale']['NL']['page']['subtitle2'] = '';
|
||||
$opt['locale']['NL']['country'] = 'NL';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['IT']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['IT']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['IT']['format']['date'] = '%x';
|
||||
$opt['locale']['IT']['format']['datelong'] = '%d. %B %Y';
|
||||
@ -154,11 +163,14 @@
|
||||
$opt['locale']['IT']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['IT']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['IT']['format']['timesec'] = '%X';
|
||||
$opt['locale']['IT']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['IT']['country'] = 'IT';
|
||||
$opt['locale']['IT']['page']['subtitle1'] = 'Geocaching con Opencaching';
|
||||
$opt['locale']['IT']['page']['subtitle2'] = '';
|
||||
$opt['locale']['IT']['page']['license_url'] = 'http://creativecommons.org/licenses/by-nc-nd/3.0/de/deed.it';
|
||||
$opt['locale']['IT']['page']['license'] = '<a rel="license" href="%1" target="_blank"><img alt="Creative Commons License Terms" style="border-width:0" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a><br />Il contenuto di www.opencaching.de è rilasciato sotto <br />Licenza <a rel="license" href="%1" target="_blank">Attribuzione - Non commerciale - Non opere derivate 3.0 Germania</a>.';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['RU']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['RU']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['RU']['format']['date'] = '%x';
|
||||
$opt['locale']['RU']['format']['datelong'] = '%d. %B %Y';
|
||||
@ -166,9 +178,10 @@
|
||||
$opt['locale']['RU']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['RU']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['RU']['format']['timesec'] = '%X';
|
||||
$opt['locale']['RU']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['RU']['country'] = 'RU';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['ES']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['ES']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['ES']['format']['date'] = '%x';
|
||||
$opt['locale']['ES']['format']['datelong'] = '%d. %B %Y';
|
||||
@ -176,11 +189,14 @@
|
||||
$opt['locale']['ES']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['ES']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['ES']['format']['timesec'] = '%X';
|
||||
$opt['locale']['ES']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['ES']['country'] = 'ES';
|
||||
$opt['locale']['ES']['page']['subtitle1'] = 'Geocaching con Opencaching';
|
||||
$opt['locale']['ES']['page']['subtitle2'] = '';
|
||||
$opt['locale']['ES']['page']['license_url'] = 'http://creativecommons.org/licenses/by-nc-nd/3.0/de/deed.es_ES';
|
||||
$opt['locale']['ES']['page']['license'] = '<a rel="license" href="%1" target="_blank"><img alt="Creative Commons License Terms" style="border-width:0" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a><br />El contenido está disponible bajo licencia <br/><a rel="license" href="%1" target="_blank">Reconocimiento-NoComercial-SinObraDerivada 3.0 Alemania</a> Licencia.';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['SV']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['SV']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['SV']['format']['date'] = '%Y-%m-%d';
|
||||
$opt['locale']['SV']['format']['datelong'] = '%Y-%m-%d';
|
||||
@ -188,11 +204,12 @@
|
||||
$opt['locale']['SV']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['SV']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['SV']['format']['timesec'] = '%X';
|
||||
$opt['locale']['SV']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['SV']['country'] = 'SE';
|
||||
$opt['locale']['SV']['page']['subtitle1'] = 'Geocaching med Opencaching';
|
||||
$opt['locale']['SV']['page']['subtitle2'] = '';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['NO']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['NO']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['NO']['format']['date'] = '%Y-%m-%d';
|
||||
$opt['locale']['NO']['format']['datelong'] = '%Y-%m-%d';
|
||||
@ -200,11 +217,12 @@
|
||||
$opt['locale']['NO']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['NO']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['NO']['format']['timesec'] = '%X';
|
||||
$opt['locale']['NO']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['NO']['country'] = 'NO';
|
||||
$opt['locale']['NO']['page']['subtitle1'] = 'Geocaching med Opencaching';
|
||||
$opt['locale']['NO']['page']['subtitle2'] = '';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['DA']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['DA']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['DA']['format']['date'] = '%Y-%m-%d';
|
||||
$opt['locale']['DA']['format']['datelong'] = '%Y-%m-%d';
|
||||
@ -212,11 +230,12 @@
|
||||
$opt['locale']['DA']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['DA']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['DA']['format']['timesec'] = '%X';
|
||||
$opt['locale']['DA']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['DA']['country'] = 'DK';
|
||||
$opt['locale']['DA']['page']['subtitle1'] = 'Geocaching med Opencaching';
|
||||
$opt['locale']['DA']['page']['subtitle2'] = '';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['PT']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['PT']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['PT']['format']['date'] = '%Y-%m-%d';
|
||||
$opt['locale']['PT']['format']['datelong'] = '%Y-%m-%d';
|
||||
@ -224,11 +243,12 @@
|
||||
$opt['locale']['PT']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['PT']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['PT']['format']['timesec'] = '%X';
|
||||
$opt['locale']['PT']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['PT']['country'] = 'PT';
|
||||
$opt['locale']['PT']['page']['subtitle1'] = 'Geocaching com Opencaching';
|
||||
$opt['locale']['PT']['page']['subtitle2'] = '';
|
||||
|
||||
$opt['locale']['DE']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['JA']['format']['dateshort'] = '%d.%m.%y';
|
||||
$opt['locale']['JA']['format']['dm'] = '%d.%m.';
|
||||
$opt['locale']['JA']['format']['date'] = '%Y-%m-%d';
|
||||
$opt['locale']['JA']['format']['datelong'] = '%Y-%m-%d';
|
||||
@ -236,6 +256,7 @@
|
||||
$opt['locale']['JA']['format']['datetimesec'] = '%x %X';
|
||||
$opt['locale']['JA']['format']['time'] = '%H:%M';
|
||||
$opt['locale']['JA']['format']['timesec'] = '%X';
|
||||
$opt['locale']['JA']['format']['phpdate'] = 'd-m-Y';
|
||||
$opt['locale']['JA']['country'] = 'JP';
|
||||
$opt['locale']['JA']['page']['subtitle1'] = 'Opencachingとジオキャッシング';
|
||||
$opt['locale']['JA']['page']['subtitle2'] = '';
|
||||
|
@ -365,6 +365,12 @@
|
||||
$opt['logic']['logs']['purge_email'] = 30;
|
||||
$opt['logic']['logs']['purge_userdata'] = 14;
|
||||
|
||||
/* license-related functions
|
||||
*/
|
||||
$opt['logic']['license'] = array(); // PHP warning without this - why only here??
|
||||
$opt['logic']['license']['admin'] = true;
|
||||
$opt['logic']['license']['disclaimer'] = false; // also in lib/settings.inc.php
|
||||
|
||||
/* Database charset
|
||||
* frontend and php charsets are UTF-8
|
||||
* here you can set a different charset for the MySQL-Engine
|
||||
|
@ -52,3 +52,5 @@ date commit ID change
|
||||
2013-03-14 69abeb67 added fields coordinates_type.preposition and pp_trans_id
|
||||
2013-03-15 a15b5582 discarded table 'data_license'
|
||||
2013-03-16 added fields coordinates.date_created and .last_modified
|
||||
2013-03-18 added table 'saved_texts' + triggers
|
||||
added triggers to table 'coordinates'
|
||||
|
@ -856,11 +856,11 @@ INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustrin
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('34', 'MNU_ERROR', 'Error message', '133', 'Error message', '133', '0', '', '0', '0', '9', '#D5D9FF', '0', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('35', 'MNU_ADMIN_TRANSLATE', 'Translation', '126', 'Translation', '126', '1', 'translate.php', '1', '12', '1', '', '0', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('36', 'MNU_MYPROFILE_OVERVIEW', 'My profile', '119', 'Overview', '483', '0', 'myhome.php', '1', '9', '1', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('37', 'MNU_MYPROFILE_DATA', 'Profile', '484', 'Profile', '484', '0', 'myprofile.php', '1', '9', '2', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('38', 'MNU_MYPROFILE_QUERIES', 'Stored queries', '485', 'Stored queries', '485', '0', 'query.php', '1', '9', '3', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('39', 'MNU_MYPROFILE_WATCHES', 'Watched caches', '486', 'Watched caches', '486', '0', 'mywatches.php', '1', '9', '4', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('40', 'MNU_MYPROFILE_IGNORES', 'Ignored caches', '487', 'Ignored caches', '487', '0', 'myignores.php', '1', '9', '5', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('41', 'MNU_MYPROFILE_RECOMMENDATIONS', 'Recommendations', '55', 'Recommendations', '55', '0', 'mytop5.php', '1', '9', '6', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('37', 'MNU_MYPROFILE_DATA', 'Profile', '484', 'Profile', '484', '0', 'myprofile.php', '1', '9', '3', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('38', 'MNU_MYPROFILE_QUERIES', 'Stored queries', '485', 'Stored queries', '485', '0', 'query.php', '1', '9', '4', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('39', 'MNU_MYPROFILE_WATCHES', 'Watched caches', '486', 'Watched caches', '486', '0', 'mywatches.php', '1', '9', '5', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('40', 'MNU_MYPROFILE_IGNORES', 'Ignored caches', '487', 'Ignored caches', '487', '0', 'myignores.php', '1', '9', '6', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('41', 'MNU_MYPROFILE_RECOMMENDATIONS', 'Recommendations', '55', 'Recommendations', '55', '0', 'mytop5.php', '1', '9', '7', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('42', 'MNU_MYPROFILE_WATCHES_EDIT', 'Settings', '488', 'Settings', '488', '0', 'mywatches.php?action=edit', '1', '39', '1', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('43', 'MNU_MYPROFILE_DATA_EDIT', 'Edit profile', '489', 'Edit profile', '489', '0', 'myprofile.php?action=change', '1', '37', '1', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('44', 'MNU_MYPROFILE_DATA_EMAIL', 'E-Mail Address', '493', 'E-Mail Address', '493', '0', 'newemail.php', '1', '37', '2', '', '1', NULL);
|
||||
@ -881,7 +881,7 @@ INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustrin
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('60', 'MNU_MYPROFILE_DETAILS', 'My details', '799', 'My details', '799', '0', 'mydetails.php', '1', '37', '1', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('61', 'MNU_MYPROFILE_DETAILS_EDIT', 'Edit details', '800', 'Edit details', '800', '0', 'mydetails.php?action=change', '1', '37', '1', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('62', 'MNU_CACHES_USERDETAILS', 'User details', '801', 'User details', '801', '0', 'viewuserdetails.php', '0', '10', '4', '', '0', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('63', 'MNU_MYPROFILE_ADOPT', 'Adoptions', '827', 'Adoptions', '827', '0', 'adoptcache.php', '1', '9', '7', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('63', 'MNU_MYPROFILE_ADOPT', 'Adoptions', '827', 'Adoptions', '827', '0', 'adoptcache.php', '1', '9', '8', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('64', 'MNU_CACHES_ADOPT', 'Adoptions', '827', 'Adoptions', '827', '0', 'adoptcache.php', '0', '10', '9', '', '0', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('65', 'MNU_ADMIN_USER', 'Manage User', '859', 'Manage User', '859', '0', 'adminuser.php', '1', '12', '4', '', '0', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('66', 'MNU_ADMIN_NEWS', 'News approve', '873', 'News approve', '873', '1', 'newsapprove.php', '1', '12', '5', '', '0', NULL);
|
||||
@ -896,6 +896,7 @@ INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustrin
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('89', 'MNU_ADMIN_ADMINS', 'Admins', '1831', 'Admins', '1831', '1', 'admins.php', '1', '12', '6', '', '0', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('90', 'MNU_START_NEWLOGPICS', 'Picture gallery', '1940', 'Picture gallery', '1940', '0', 'newlogpics.php', '1', '7', '7', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('91', 'MNU_START_OPENCACHING', 'About Opencaching', '1963', 'About Opencaching', '1963', '0', 'http://wiki.opencaching.de/index.php/Opencaching.de', '1', '1', '2', '', '1', NULL);
|
||||
INSERT INTO `sys_menu` (`id`, `id_string`, `title`, `title_trans_id`, `menustring`, `menustring_trans_id`, `access`, `href`, `visible`, `parent`, `position`, `color`, `sitemap`, `only_if_parent`) VALUES ('92', 'MNU_MYPROFILE_PUBLIC', 'Public profile', '1952', 'Public profile', '1952', '0', 'viewprofile.php', '1', '9', '2', '', '1', NULL);
|
||||
|
||||
-- Table sys_trans
|
||||
SET NAMES 'utf8';
|
||||
@ -2373,7 +2374,7 @@ INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1948', 'Your lo
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1949', 'Your latest log pictures', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1950', 'In your <a href=\"mydetails.php\">profile settings</a> you can choose if your log pictures stat and gallery is visible for other users.', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1951', 'This is what your profile looks like to other users:', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1952', 'Your public profile', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1952', 'Public profile', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1953', 'You did not upload any log pictures yet.', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1954', 'Pictures marked as spoiler are not shown; therefore the number of pictures on this page can be smaller than in the profile statistics.', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1955', 'Other information', '2013-02-23 19:00:04');
|
||||
@ -2385,6 +2386,10 @@ INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1960', 'Page',
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1961', 'to ', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1962', 'at', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1963', 'About Opencaching', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1964', 'Cache descriptions, log texts and pictures have been deleted, because the account was disabled before transition to the <a href=\"articles.php?page=impressum#datalicense\">new data license</a>.', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1965', 'cache description was removed because the owner\'s account was inactive when the <a href=\"articles.php?page=impressum#datalicense\">new content license</a> was launched', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1966', 'as of', '2013-02-23 19:00:04');
|
||||
INSERT INTO `sys_trans` (`id`, `text`, `last_modified`) VALUES ('1967', 'all log entries © their authors', '2013-02-23 19:00:04');
|
||||
|
||||
-- Table sys_trans_ref
|
||||
SET NAMES 'utf8';
|
||||
@ -6037,7 +6042,7 @@ INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUE
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1949', 'DE', 'Deine neuesten Logbilder', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1950', 'DE', 'In deinen <a href=\"mydetails.php\">Profileinstellungen</a> kannst du festlegen, ob deine Logbild-Statistik und -Galerie für andere Benutzer sichtbar sein soll oder nicht.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1951', 'DE', 'So sieht dein Profil für andere Benutzer aus:', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1952', 'DE', 'Dein öffentliches Profil', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1952', 'DE', 'Öffentliches Profil', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1953', 'DE', 'Du hast noch keine Logbilder hochgeladen.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1954', 'DE', 'Als Spoiler markierte Bilder werden nicht angezeigt; daher kann die Zahl der Bilder auf dieser Seite geringer sein als in der Benutzerstatistik.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1955', 'DE', 'Sonstige Informationen', '2013-02-19 05:48:07');
|
||||
@ -6049,6 +6054,10 @@ INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUE
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1961', 'DE', 'zu', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1962', 'DE', 'bei', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1963', 'DE', 'Über Opencaching', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1964', 'DE', 'Cachebeschreibungen, Logtexte und Bilder des Benutzers wurden entfernt, weil die Deaktivierung vor der Umstellung auf die <a href=\"articles.php?page=impressum#datalicense\">neue Datenlizenz</a> stattfand.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1965', 'DE', 'Das Benutzerkonto des Cachebesitzers war zum Zeitpunkt der Umstellung auf die <a href=\"articles.php?page=impressum#datalicense\">neue Datenlizenz</a> nicht mehr aktiv. Da er der neuen Lizenz nicht zustimmen konnte, wurden seine Cachebeschreibungen entfernt.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1966', 'DE', 'Stand:', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1967', 'DE', 'alle Logeinträge © jeweiliger Autor', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1', 'EN', 'Reorder IDs \r', '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');
|
||||
@ -7522,7 +7531,7 @@ INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUE
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1949', 'EN', 'Your latest log pictures', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1950', 'EN', 'In your <a href=\"mydetails.php\">profile settings</a> you can choose if your log pictures stat and gallery is visible for other users.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1951', 'EN', 'This is what your profile looks like to other users:', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1952', 'EN', 'Your public profile', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1952', 'EN', 'Public profile', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1953', 'EN', 'You did not upload any log pictures yet.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1954', 'EN', 'Pictures marked as spoiler are not shown; therefore the number of pictures on this page can be smaller than in the profile statistics.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1955', 'EN', 'Other information', '2013-02-19 05:48:07');
|
||||
@ -7534,6 +7543,10 @@ INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUE
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1961', 'EN', 'to', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1962', 'EN', 'at', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1963', 'EN', 'About Opencaching', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1964', 'EN', 'Cache descriptions, log texts and pictures have been deleted, because the account was disabled before transition to the <a href=\"articles.php?page=impressum#datalicense\">new data license</a>.', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1965', 'EN', 'cache description was removed because the owner\'s account was inactive when the <a href=\"articles.php?page=impressum#datalicense\">new content license</a> was launched', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1966', 'EN', 'as of', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1967', 'EN', 'all log entries © their authors', '2013-02-19 05:48:07');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1', 'ES', 'Reordenar ID', '2010-12-09 00:17:55');
|
||||
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');
|
||||
@ -9006,7 +9019,7 @@ INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUE
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1949', 'ES', 'Los log de las imagenes', '2013-03-16 17:23:42');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1950', 'ES', 'En la configuración del perfil <a href=\"mydetails.php\"> </a> se puede elegir si el registro de imágenes de estadísticas y galería es visible para otros usuarios.', '2013-03-16 17:23:42');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1951', 'ES', 'Esto es lo que su perfil se parece a otros usuarios:', '2013-03-16 17:23:42');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1952', 'ES', 'Tu perfil público', '2013-03-16 17:23:42');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1952', 'ES', 'Perfil público', '2013-03-16 17:23:42');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1953', 'ES', 'No has subido ninguna foto aún de registro.', '2013-03-16 17:23:42');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1954', 'ES', 'Las fotografías marcadas como spoiler no se muestran, por lo que el número de imágenes en esta página puede ser menor que en las estadísticas de perfil.', '2013-03-16 17:23:42');
|
||||
INSERT INTO `sys_trans_text` (`trans_id`, `lang`, `text`, `last_modified`) VALUES ('1955', 'ES', 'Otra información', '2013-03-16 17:23:42');
|
||||
|
@ -1294,6 +1294,16 @@
|
||||
END IF;
|
||||
END;");
|
||||
|
||||
sql_dropTrigger('coordinatesAfterInsert');
|
||||
sql("CREATE TRIGGER `coordinatesAfterInsert` AFTER INSERT ON `coordinates`
|
||||
FOR EACH ROW
|
||||
BEGIN
|
||||
/* dont overwrite date values while XML client is running */
|
||||
IF ISNULL(@XMLSYNC) OR @XMLSYNC!=1 AND NEW.`type`=1 THEN
|
||||
UPDATE `caches` SET `last_modified`=NOW() WHERE `caches`.`cache_id`=NEW.`cache_id`;
|
||||
END IF;
|
||||
END;");
|
||||
|
||||
sql_dropTrigger('coordinatesBeforeUpdate');
|
||||
sql("CREATE TRIGGER `coordinatesBeforeUpdate` BEFORE UPDATE ON `coordinates`
|
||||
FOR EACH ROW
|
||||
@ -1304,4 +1314,34 @@
|
||||
END IF;
|
||||
END;");
|
||||
|
||||
sql_dropTrigger('coordinatesAfterUpdate');
|
||||
sql("CREATE TRIGGER `coordinatesAfterUpdate` AFTER UPDATE ON `coordinates`
|
||||
FOR EACH ROW
|
||||
BEGIN
|
||||
/* dont overwrite date values while XML client is running */
|
||||
IF ISNULL(@XMLSYNC) OR @XMLSYNC!=1 AND NEW.`type`=1 THEN
|
||||
UPDATE `caches` SET `last_modified`=NOW() WHERE `caches`.`cache_id`=NEW.`cache_id`;
|
||||
END IF;
|
||||
END;");
|
||||
|
||||
sql_dropTrigger('coordinatesAfterDelete');
|
||||
sql("CREATE TRIGGER `coordinatesAfterDelete` AFTER DELETE ON `coordinates`
|
||||
FOR EACH ROW
|
||||
BEGIN
|
||||
/* dont overwrite date values while XML client is running */
|
||||
IF ISNULL(@XMLSYNC) OR @XMLSYNC!=1 AND OLD.`type`=1 THEN
|
||||
UPDATE `caches` SET `last_modified`=NOW() WHERE `caches`.`cache_id`=OLD.`cache_id`;
|
||||
END IF;
|
||||
END;");
|
||||
|
||||
sql_dropTrigger('savedTextsBeforeInsert');
|
||||
sql("CREATE TRIGGER `savedTextsBeforeInsert` BEFORE INSERT ON `saved_texts`
|
||||
FOR EACH ROW
|
||||
BEGIN
|
||||
/* dont overwrite date values while XML client is running */
|
||||
IF ISNULL(@XMLSYNC) OR @XMLSYNC!=1 THEN
|
||||
SET NEW.`date_created`=NOW();
|
||||
END IF;
|
||||
END;");
|
||||
|
||||
?>
|
@ -2,6 +2,8 @@ SET NAMES 'utf8';
|
||||
DROP TABLE IF EXISTS `coordinates`;
|
||||
CREATE TABLE `coordinates` (
|
||||
`id` int(11) NOT NULL auto_increment,
|
||||
`date_created` datetime NOT NULL,
|
||||
`last_modified` datetime NOT NULL,
|
||||
`type` int(11) NOT NULL,
|
||||
`subtype` int(11) default NULL,
|
||||
`latitude` double NOT NULL,
|
||||
|
12
htdocs/doc/sql/tables/saved_texts.sql
Normal file
12
htdocs/doc/sql/tables/saved_texts.sql
Normal file
@ -0,0 +1,12 @@
|
||||
SET NAMES 'utf8';
|
||||
DROP TABLE IF EXISTS `saved_texts`;
|
||||
CREATE TABLE `saved_texts` (
|
||||
`id` int(10) NOT NULL auto_increment,
|
||||
`date_created` datetime NOT NULL,
|
||||
`object_type` tinyint(3) NOT NULL,
|
||||
`object_id` int(10) NOT NULL,
|
||||
`subtype` tinyint(2) NOT NULL,
|
||||
`text` mediumtext NOT NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
UNIQUE KEY `object_id` (`object_type`,`object_id`,`subtype`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ;
|
@ -22,6 +22,12 @@
|
||||
<li>neues Attribut <em>ispublishdate</em> bei cache.datecreated</li>
|
||||
<li>Ausgabe von Nano-Cachgrößen</li>
|
||||
</ul>
|
||||
<p>Ab dem 7. April 2013 gibt es folgende Ergänzung:</p>
|
||||
<ul>
|
||||
<li>Wenn beim Auruf der zusätzliche Parameter "&license=1" angegeben ist, wird bei Cachebeschreibungen und Logs ein zusätzliches Feld <license>...</license> mitgeliefert, das einen Copyright-Disclaimer gemäß <a href="http://www.opencaching.de/articles.php?page=impressum#datalicense">Datenlizenz</a> enthält. Dieser ist bei der Darstellung der Daten mit anzuzeigen und bei Weitergabe mitzuliefern. Der Disclaimer bezieht sich jeweils auch auf zugehörige Bilder und ist – soweit möglich – lokalisiert.<br />
|
||||
Wenn der license-Parameter <em>nicht</em> angegeben ist, wird der Disclaimer automatisch an alle Cachebeschreibungen angehängt. </li>
|
||||
</ul>
|
||||
|
||||
<p>Der XML-Doctype lautet in allen Versionen "oc11xml".</p>
|
||||
<h2>Ausgabeformat</h2>
|
||||
<p>
|
||||
|
@ -248,14 +248,9 @@
|
||||
?>
|
||||
|
||||
<!-- Datalicense -->
|
||||
<!--
|
||||
<p class="sidebar-maintitle">{t}Datalicense{/t}</p>
|
||||
<div style="margin-top:20px;width:100%;text-align:center;">
|
||||
<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/de/" target="_blank"><img alt="Creative Commons Lizenzvertrag" style="border-width:0" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a><br />{t}The www.opencaching.de content is licensed under <br /><a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/de/deed.en" target="_blank">Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Germany</a> License.{/t}
|
||||
<br />
|
||||
|
||||
</div>
|
||||
-->
|
||||
{license_disclaimer}
|
||||
|
||||
<!-- page statistics -->
|
||||
<div class="sidebar-txtbox-noshade">
|
||||
<p class="content-txtbox-noshade-size5">
|
||||
<small>
|
||||
|
@ -432,7 +432,7 @@ function __autoload($class_name)
|
||||
function tpl_BuildTemplate($dbdisconnect=true)
|
||||
{
|
||||
//template handling vars
|
||||
global $style, $stylepath, $tplname, $vars, $langpath, $locale, $opt, $oc_nodeid;
|
||||
global $style, $stylepath, $tplname, $vars, $langpath, $locale, $opt, $oc_nodeid, $translate;
|
||||
//language specific expression
|
||||
global $error_pagenotexist;
|
||||
//only for debbuging
|
||||
@ -460,6 +460,30 @@ function __autoload($class_name)
|
||||
tpl_set_var('opt_page_subtitle2', $opt['page']['subtitle2']);
|
||||
tpl_set_var('opt_page_title', $opt['page']['title']);
|
||||
|
||||
if ($opt['logic']['license']['disclaimer'])
|
||||
{
|
||||
if (isset($opt['locale'][$locale]['page']['license_url']))
|
||||
$lurl = $opt['locale'][$locale]['page']['license_url'];
|
||||
else
|
||||
$lurl = $opt['locale']['EN']['page']['license_url'];
|
||||
|
||||
if (isset($opt['locale'][$locale]['page']['license']))
|
||||
$ltext = $opt['locale'][$locale]['page']['license'];
|
||||
else
|
||||
$ltext = $opt['locale']['EN']['page']['license'];
|
||||
|
||||
$ld = '<p class="sidebar-maintitle">' .
|
||||
$translate->t('Datalicense', '', '', 0) .
|
||||
'</p>' .
|
||||
'<div style="margin-top:20px;width:100%;text-align:center;">' .
|
||||
mb_ereg_replace('%1', $lurl, $ltext) .
|
||||
'<br /> ' .
|
||||
'</div>';
|
||||
tpl_set_var('license_disclaimer', $ld);
|
||||
}
|
||||
else
|
||||
tpl_set_var('license_disclaimer','');
|
||||
|
||||
$bTemplateBuild = new Cbench;
|
||||
$bTemplateBuild->Start();
|
||||
|
||||
|
@ -139,6 +139,9 @@
|
||||
// without fill_gaps first)
|
||||
// fill_gaps = false: continue with the last waypoint
|
||||
$opt['logic']['waypoint_pool']['fill_gaps'] = false;
|
||||
|
||||
// data license
|
||||
$opt['logic']['license']['disclaimer'] = true; // also in lib2/settings-dist.inc.php
|
||||
|
||||
// see config2/settings-dist.inc.php
|
||||
$opt['template']['default']['locale'] = 'DE'; // may be overwritten by $opt['domain'][...]['locale']
|
||||
|
@ -140,10 +140,10 @@ class OcSmarty extends Smarty
|
||||
global $opt, $db, $cookie, $login, $menu, $sqldebugger, $translate;
|
||||
$cookie->close();
|
||||
|
||||
// // if the user is an admin, dont cache the content
|
||||
// if (isset($login))
|
||||
// if ($login->admin)
|
||||
// $this->caching = false;
|
||||
// if the user is an admin, dont cache the content
|
||||
if (isset($login))
|
||||
if ($login->admin)
|
||||
$this->caching = false;
|
||||
|
||||
//Give Smarty access to the whole options array.
|
||||
$this->assign('siteSettings', $opt);
|
||||
@ -152,13 +152,15 @@ class OcSmarty extends Smarty
|
||||
//access using the siteSettings above?
|
||||
// assign main template vars
|
||||
// ... and some of the $opt
|
||||
$locale = $opt['template']['locale'];
|
||||
|
||||
$optn['debug'] = $opt['debug'];
|
||||
$optn['template']['locales'] = $opt['template']['locales'];
|
||||
$optn['template']['locale'] = $opt['template']['locale'];
|
||||
$optn['template']['style'] = $opt['template']['style'];
|
||||
$optn['template']['country'] = $login->getUserCountry();
|
||||
$optn['page']['subtitle1'] = isset($opt['locale'][$opt['template']['locale']]['page']['subtitle1']) ? $opt['locale'][$opt['template']['locale']]['page']['subtitle1'] : $opt['page']['subtitle1'];
|
||||
$optn['page']['subtitle2'] = isset($opt['locale'][$opt['template']['locale']]['page']['subtitle2']) ? $opt['locale'][$opt['template']['locale']]['page']['subtitle2'] : $opt['page']['subtitle2'];
|
||||
$optn['page']['subtitle1'] = isset($opt['locale'][$locale]['page']['subtitle1']) ? $opt['locale'][$locale]['page']['subtitle1'] : $opt['page']['subtitle1'];
|
||||
$optn['page']['subtitle2'] = isset($opt['locale'][$locale]['page']['subtitle2']) ? $opt['locale'][$locale]['page']['subtitle2'] : $opt['page']['subtitle2'];
|
||||
$optn['page']['headimagepath'] = $opt['page']['headimagepath'];
|
||||
$optn['page']['max_logins_per_hour'] = $opt['page']['max_logins_per_hour'];
|
||||
$optn['page']['absolute_url'] = $opt['page']['absolute_url'];
|
||||
@ -221,6 +223,24 @@ class OcSmarty extends Smarty
|
||||
if ($this->title == '')
|
||||
$optn['template']['title'] = $menu->GetMenuTitle();
|
||||
|
||||
|
||||
if ($opt['logic']['license']['disclaimer'])
|
||||
{
|
||||
if (isset($opt['locale'][$locale]['page']['license_url']))
|
||||
$lurl = $opt['locale'][$locale]['page']['license_url'];
|
||||
else
|
||||
$lurl = $opt['locale']['EN']['page']['license_url'];
|
||||
|
||||
if (isset($opt['locale'][$locale]['page']['license']))
|
||||
$ltext = $opt['locale'][$locale]['page']['license'];
|
||||
else
|
||||
$ltext = $opt['locale']['EN']['page']['license'];
|
||||
|
||||
$this->assign('license_disclaimer', mb_ereg_replace('%1', $lurl, $ltext));
|
||||
}
|
||||
else
|
||||
$this->assign('license_disclaimer','');
|
||||
|
||||
$this->assign('opt', $optn);
|
||||
$this->assign('login', $loginn);
|
||||
|
||||
|
@ -46,6 +46,7 @@
|
||||
define('OBJECT_TRAVELER', 5);
|
||||
define('OBJECT_PICTURE', 6);
|
||||
define('OBJECT_REMOVEDOBJECT', 7);
|
||||
define('OBJECT_WAYPOINT', 8);
|
||||
|
||||
// coordinate types
|
||||
define('COORDINATE_WAYPOINT', 1);
|
||||
@ -66,8 +67,10 @@
|
||||
define('USR_OPT_TRANSLANG', 12);
|
||||
|
||||
// user.data_license values
|
||||
define('OLD_DATA_LICSENSE',0); // deadline not reached
|
||||
define('NEW_DATA_LICENSE_DECLINED',1); // declined license
|
||||
define('NEW_DATA_LICSENSE_ACTIVELY_ACCEPTED',1); // accepted new license on registration
|
||||
define('NEW_DATA_LICSENSE_PASSIVELY_ACCEPTED',2); // did not decline license until deadline
|
||||
define('OLD_DATA_LICSENSE',0); // before deadline
|
||||
define('NEW_DATA_LICENSE_ACTIVELY_DECLINED',1); // declined license
|
||||
define('NEW_DATA_LICENSE_ACTIVELY_ACCEPTED',2); // accepted new license on registration
|
||||
define('NEW_DATA_LICENSE_PASSIVELY_ACCEPTED',3); // did not decline license until deadline
|
||||
define('NEW_DATA_LICENSE_PASSIVELY_DECLINED',4); // could accept/decline because disabled
|
||||
|
||||
?>
|
@ -133,19 +133,21 @@ function get_logpics($purpose, $userid=0, $cacheid=0)
|
||||
break;
|
||||
|
||||
case LOGPICS_FOR_CACHE_STAT:
|
||||
// all pictures for a cache
|
||||
// all pictures for a cache except license-replacement pics
|
||||
// need not to exclude invisible caches, as this is only displayed in listing view
|
||||
|
||||
$result = sql_value(
|
||||
"SELECT COUNT(*)
|
||||
FROM `pictures` AS `pics`
|
||||
$join_logs
|
||||
WHERE `object_type`=1 AND `logs`.`cache_id`='&1'",
|
||||
0, $cacheid);
|
||||
$join_user
|
||||
WHERE `object_type`=1 AND `logs`.`cache_id`='&1'
|
||||
AND NOT (`data_license` IN ('&2','&3'))",
|
||||
0, $cacheid, NEW_DATA_LICENSE_ACTIVELY_DECLINED, NEW_DATA_LICENSE_PASSIVELY_DECLINED);
|
||||
break;
|
||||
|
||||
case LOGPICS_FOR_CACHE_GALLERY:
|
||||
// all picture for a cache
|
||||
// all picture for a cache except license-replacement pics
|
||||
// for all users except owner: also excluding invisble caches
|
||||
|
||||
$rs = sql("SELECT $fields, `user`.`username`, `logs`.`date` AS `picdate`
|
||||
@ -154,7 +156,9 @@ function get_logpics($purpose, $userid=0, $cacheid=0)
|
||||
($userid == $login->userid ? "" : "$join_caches $join_cachestatus") . "
|
||||
$join_user
|
||||
WHERE `object_type`=1 AND `logs`.`cache_id`='&1'
|
||||
ORDER BY `logs`.`date` DESC", $cacheid);
|
||||
AND NOT (`data_license` IN ('&2','&3'))
|
||||
ORDER BY `logs`.`date` DESC",
|
||||
$cacheid, NEW_DATA_LICENSE_ACTIVELY_DECLINED, NEW_DATA_LICENSE_PASSIVELY_DECLINED);
|
||||
break;
|
||||
|
||||
default:
|
||||
|
@ -12,6 +12,7 @@ require_once($opt['rootpath'] . 'lib2/mail.class.php');
|
||||
require_once($opt['rootpath'] . 'lib2/logic/rowEditor.class.php');
|
||||
require_once($opt['rootpath'] . 'lib2/logic/statpic.class.php');
|
||||
require_once($opt['rootpath'] . 'lib2/logic/countriesList.class.php');
|
||||
require_once($opt['rootpath'] . 'lib2/logic/picture.class.php');
|
||||
require_once($opt['rootpath'] . 'lib2/logic/cracklib.inc.php');
|
||||
require_once($opt['rootpath'] . 'lib2/translate.class.php');
|
||||
|
||||
@ -744,32 +745,39 @@ class user
|
||||
* disables user (if not disabled), removes all licensed content from db and
|
||||
* replaces every picture with a dummy one
|
||||
*
|
||||
* @return bool false, if anything went wrong, true otherwise
|
||||
* @return string error message, if anything went wrong, true otherwise
|
||||
*
|
||||
* old_disabled: the user was disabled already before license transition
|
||||
* and therefore could not accept/decline the license
|
||||
*/
|
||||
function disduelicense() {
|
||||
function disduelicense($old_disabled=false) {
|
||||
|
||||
// get translation-object
|
||||
global $translate;
|
||||
|
||||
|
||||
// check if disabled, disable if not
|
||||
if (!$this->canDisableDueLicense())
|
||||
return 'this user must not be disabled';
|
||||
if ($this->canDisable())
|
||||
if (!$this->disable())
|
||||
return 'disable user failed';
|
||||
|
||||
if (!$old_disabled)
|
||||
if ($this->canDisable())
|
||||
if (!$this->disable())
|
||||
return 'disable user failed';
|
||||
|
||||
// remember that data license was declined
|
||||
sql("UPDATE user SET data_license=1 WHERE user_id='&1'", $this->getUserId());
|
||||
sql("UPDATE user SET data_license='&2' WHERE user_id='&1'",
|
||||
$this->getUserId(),
|
||||
$old_disabled ? NEW_DATA_LICENSE_PASSIVELY_DECLINED : NEW_DATA_LICENSE_ACTIVELY_DECLINED);
|
||||
|
||||
/*
|
||||
* set all cache_desc and hint to ''
|
||||
* set all cache_desc and hint to '', save old texts
|
||||
*/
|
||||
// check if there are caches
|
||||
$num_caches = sql_value("SELECT COUNT(*) FROM `caches` WHERE `user_id`='&1'",
|
||||
0, $this->getUserId());
|
||||
if ($num_caches > 0) {
|
||||
$cache_descs = array();
|
||||
$rs = sql("SELECT `cache_desc`.`id`,`cache_desc`.`language` " .
|
||||
$rs = sql("SELECT `id`, `language`, `desc`, `hint` " .
|
||||
"FROM `cache_desc`,`caches` " .
|
||||
"WHERE `caches`.`cache_id`=`cache_desc`.`cache_id` " .
|
||||
"AND `caches`.`user_id`='&1'",
|
||||
@ -782,41 +790,96 @@ class user
|
||||
// walk through cache_descs and set message for each language
|
||||
foreach ($cache_descs as $desc)
|
||||
{
|
||||
// save text - added 2013/03/18 to be enable restoring data on reactivation
|
||||
// of accounts that were disabled before license transition
|
||||
if ($desc['desc'] != "")
|
||||
sql("INSERT IGNORE INTO `saved_texts` (`object_type`, `object_id`, `subtype`, `text`)
|
||||
VALUES ('&1', '&2', '&3', '&4')",
|
||||
OBJECT_CACHEDESC, $desc['id'], 1, $desc['desc'] );
|
||||
if ($desc['hint'] != "")
|
||||
sql("INSERT IGNORE INTO `saved_texts` (`object_type`, `object_id`, `subtype`, `text`)
|
||||
VALUES ('&1', '&2', '&3', '&4')",
|
||||
OBJECT_CACHEDESC, $desc['id'], 2, $desc['hint'] );
|
||||
|
||||
if ($desc['desc'] != "")
|
||||
if ($old_disabled)
|
||||
$descmsg = $translate->t('cache description was removed because the owner\'s account was inactive when the <a href="articles.php?page=impressum#datalicense">new content license</a> was launched', '', basename(__FILE__), __LINE__, '', 1, $desc['language']);
|
||||
else
|
||||
$descmsg = $translate->t('cache description was removed because owner declined content license', '', basename(__FILE__), __LINE__, '', 1, $desc['language']);
|
||||
else
|
||||
$descmsg = "";
|
||||
|
||||
sql("UPDATE `cache_desc` " .
|
||||
"SET `desc`='&1',`hint`='&2' " .
|
||||
"WHERE `id`='&3'",
|
||||
"<em>" . $translate->t('cache description was removed because owner declined content license', '', basename(__FILE__), __LINE__, '', 1, $desc['language']) . "</em>",
|
||||
"<em>" . $descmsg . "</em>",
|
||||
'',
|
||||
$desc['id']
|
||||
);
|
||||
);
|
||||
}
|
||||
|
||||
// replace pictures
|
||||
$errmesg = $this->replace_pictures(OBJECT_CACHE);
|
||||
if ($errmesg !== true)
|
||||
return "removing cache pictures: $errmesg";
|
||||
}
|
||||
}
|
||||
|
||||
// delete additional waypoint texts
|
||||
$rs = sql("SELECT `id`, `description` FROM `coordinates`
|
||||
WHERE `type`='&1'
|
||||
AND `cache_id` IN (SELECT `cache_id` FROM `caches` WHERE `user_id`='&2')",
|
||||
COORDINATE_WAYPOINT, $this->getUserId());
|
||||
while ($wp = sql_fetch_assoc($rs))
|
||||
{
|
||||
if ($wp['description'] != "")
|
||||
sql("INSERT IGNORE INTO `saved_texts` (`object_type`, `object_id`, `subtype`, `text`)
|
||||
VALUES ('&1', '&2', '&3', '&4')",
|
||||
OBJECT_WAYPOINT, $wp['id'], 0, $wp['description'] );
|
||||
|
||||
sql("UPDATE `coordinates` SET `description`=''
|
||||
WHERE `id`='&1'",
|
||||
$wp['id']);
|
||||
}
|
||||
sql_free_result($rs);
|
||||
|
||||
/*
|
||||
* set all cache_logs ''
|
||||
* set all cache_logs '', save old texts and delete pictures
|
||||
*/
|
||||
// check if there are cache_logs
|
||||
$num_cache_logs = sql_value("SELECT COUNT(*) " .
|
||||
"FROM `cache_logs` " .
|
||||
"WHERE `user_id`='&1'",
|
||||
0,
|
||||
$this->getUserId()
|
||||
);
|
||||
$rs = sql("SELECT `id`, `text`
|
||||
FROM `cache_logs`
|
||||
WHERE `user_id`='&1'",
|
||||
$this->getUserId()
|
||||
);
|
||||
while ($log = sql_fetch_array($rs,MYSQL_ASSOC))
|
||||
{
|
||||
// save text - added 2013/03/18 to be enable restoring data on reactivation
|
||||
// of accounts that were disabled before license transition
|
||||
sql("INSERT IGNORE INTO `saved_texts` (`object_type`, `object_id`, `subtype`, `text`)
|
||||
VALUES ('&1', '&2', '&3', '&4')",
|
||||
OBJECT_CACHELOG, $log['id'], 0, $log['text']);
|
||||
|
||||
if ($num_cache_logs > 0) {
|
||||
// set text ''
|
||||
sql("UPDATE `cache_logs` SET `text`='' WHERE `user_id`='&1'", $this->getUserId());
|
||||
sql("UPDATE `cache_logs` SET `text`='' WHERE `id`='&1'", $log['id']);
|
||||
|
||||
/*
|
||||
// replace pictures
|
||||
$errmesg = $this->replace_pictures(OBJECT_CACHELOG);
|
||||
if ($errmesg !== true)
|
||||
return "removing log pictures: $errmesg";
|
||||
*/
|
||||
|
||||
// delete log pictures
|
||||
$rsp = sql("SELECT `id` FROM `pictures`
|
||||
WHERE `object_type`='&1' AND `object_id`='&2'",
|
||||
OBJECT_CACHELOG, $log['id']);
|
||||
while ($pic = sql_fetch_assoc($rsp))
|
||||
{
|
||||
$picture = new picture($pic['id']);
|
||||
$picture->delete();
|
||||
}
|
||||
sql_free_result($rsp);
|
||||
}
|
||||
sql_free_result($rs);
|
||||
|
||||
// success
|
||||
return true;
|
||||
@ -892,8 +955,8 @@ class user
|
||||
$filenames[] = substr($url['url'],-40);
|
||||
|
||||
// free result
|
||||
sql_free_result($rs);
|
||||
|
||||
sql_free_result($rs);
|
||||
|
||||
/*
|
||||
* walk through filenames and replace original
|
||||
*/
|
||||
@ -1125,6 +1188,17 @@ class user
|
||||
return $this->reUser->getValue('email_problems') % 1000000;
|
||||
}
|
||||
|
||||
function getDataLicense()
|
||||
{
|
||||
return $this->reUser->getValue('data_license');
|
||||
}
|
||||
|
||||
function getLicenseDeclined()
|
||||
{
|
||||
return $this->getDataLicense() == NEW_DATA_LICENSE_ACTIVELY_DECLINED ||
|
||||
$this->getDataLicense() == NEW_DATA_LICENSE_PASSIVELY_DECLINED;
|
||||
}
|
||||
|
||||
function missedDataLicenseMail()
|
||||
{
|
||||
return $this->reUser->getValue('email_problems') > 1000000;
|
||||
|
@ -45,10 +45,18 @@ class translate
|
||||
if (($lang === null) || ($lang == $opt['template']['locale']))
|
||||
$trans = gettext($search);
|
||||
else
|
||||
$trans = sql_value("SELECT IFNULL(`sys_trans_text`.`text`, '&3')
|
||||
FROM `sys_trans`
|
||||
LEFT JOIN `sys_trans_text` ON `sys_trans`.`id`=`sys_trans_text`.`trans_id` AND `sys_trans_text`.`lang`='&1'
|
||||
WHERE `sys_trans`.`text`='&2' LIMIT 1", '', $lang, $search, $message);
|
||||
{
|
||||
// do not use sql_value(), as this is also used from lib1
|
||||
$rs = sql("SELECT IFNULL(`sys_trans_text`.`text`, '&3')
|
||||
FROM `sys_trans`
|
||||
LEFT JOIN `sys_trans_text` ON `sys_trans`.`id`=`sys_trans_text`.`trans_id` AND `sys_trans_text`.`lang`='&1'
|
||||
WHERE `sys_trans`.`text`='&2' LIMIT 1", $lang, $search, $message);
|
||||
if ($r = sql_fetch_array($rs))
|
||||
$trans = $r[0];
|
||||
else
|
||||
$trans = '';
|
||||
sql_free_result($rs);
|
||||
}
|
||||
|
||||
// safe w/o mb because asc(%) < 128
|
||||
if (strpos($trans, "%")>=0)
|
||||
|
@ -289,7 +289,8 @@ function output_cachexml($sWaypoint)
|
||||
LEFT JOIN `caches_attributes` ON `caches_attributes`.`cache_id`=`caches`.`cache_id` AND `caches_attributes`.`attrib_id`=6
|
||||
LEFT JOIN `pictures` ON `pictures`.`object_id`=`caches`.`cache_id` AND `pictures`.`object_type`='&4' AND `pictures`.`mappreview`=1
|
||||
WHERE (`caches`.`wp_oc`='&3' OR (`caches`.`wp_oc`!='&3' AND `caches`.`wp_gc`='&3') OR (`caches`.`wp_oc`!='&3' AND `caches`.`wp_nc`='&3')) AND
|
||||
(`cache_status`.`allow_user_view`=1 OR `caches`.`user_id`='&1')",
|
||||
(`cache_status`.`allow_user_view`=1 OR `caches`.`user_id`='&1')
|
||||
LIMIT 1", // for the case of illegal duplicates in pictures.mappreview etc.
|
||||
$login->userid, $opt['template']['locale'], $sWaypoint, OBJECT_CACHE);
|
||||
|
||||
$rCache = sql_fetch_assoc($rsCache);
|
||||
|
@ -5,6 +5,14 @@ General Public License as published by the Free Software Foundation, either
|
||||
version 3 of the License, or (at your option) any later version. See LICENSE.TXT
|
||||
for details. */
|
||||
|
||||
// disable non-javascript fallback links do that enlargeit receives the mouse clicks
|
||||
function remove_piclinks()
|
||||
{
|
||||
var piclinks = document.getElementsByName("piclink");
|
||||
for (var pic=0; pic<piclinks.length; pic++)
|
||||
piclinks[pic].removeAttribute('href');
|
||||
}
|
||||
|
||||
// modify these
|
||||
var enl_gifpath='./resource2/ocstyle/js/enlargeit/'; // path to graphics
|
||||
var enl_brdsize=6; // border thickness (5-30)
|
||||
|
@ -105,10 +105,12 @@
|
||||
|
||||
<tr><td class="spacer" colspan="2"></td></tr>
|
||||
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="checkbox" name="chkdisduelicense" value="1" /> {t}Disable (and lock all geocaches owned) and remove all foreign licensed content{/t}</td>
|
||||
</tr>
|
||||
{if $licensefunctions==true}
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="checkbox" name="chkdisduelicense" value="1" /> {t}Disable (and lock all geocaches owned) and remove all foreign licensed content{/t}</td>
|
||||
</tr>
|
||||
{/if}
|
||||
|
||||
{if $candisable==true}
|
||||
<tr>
|
||||
@ -125,11 +127,11 @@
|
||||
{if $cansetemail==true}
|
||||
<tr>
|
||||
<td></td>
|
||||
<td><input type="checkbox" name="chkemail" value="1"> {t}Mark e-mail address as invalid{/t} <input type="checkbox" name="chkdl" value="1"> {t}data license mail was not delivered{/t}</td>
|
||||
<td><input type="checkbox" name="chkemail" value="1"> {t}Mark e-mail address as invalid{/t}{if $licensefunctions} <input type="checkbox" name="chkdl" value="1"> {t}data license mail was not delivered{/t}{/if}</td>
|
||||
</tr>
|
||||
{/if}
|
||||
|
||||
{* {if $candelete==true || $candisable==true} *}
|
||||
{if $licensefunctions==true || $candelete==true || $candisable==true || $cansetemail==true}
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="checkbox" name="chkcommit" value="1" /> {t}Sure?{/t}</td>
|
||||
@ -140,7 +142,7 @@
|
||||
<td> </td>
|
||||
<td><input type="submit" name="execute" value="{t}Submit{/t}" class="formbutton" onclick="submitbutton('execute')" /></td>
|
||||
</tr>
|
||||
{* {/if} *}
|
||||
{/if}
|
||||
</table>
|
||||
</form>
|
||||
{/if}
|
||||
|
@ -238,10 +238,10 @@
|
||||
|
||||
<div class="content-txtbox-noshade" style="padding-right: 25px;">
|
||||
<p>
|
||||
<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/">
|
||||
<img alt="Creative Commons Licenseagreement" style="border: 0; padding-right: 15px; padding-bottom: 15px; float: left;" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a>
|
||||
<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/de/deed.en">
|
||||
<img alt="Creative Commons License Terms" style="border: 0; padding-right: 15px; padding-bottom: 15px; float: left;" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a>
|
||||
Starting April 7, 2013, all Opencaching.de content which has been contributed by users is licensed under
|
||||
the terms of "Creative Commons Attribution-NonCommercial-NoDerivs 3.0", which means
|
||||
the terms of "Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Germany", which means
|
||||
that you may reproduce, distribute and publish it. When doing this, the author has to
|
||||
be named in the form given below. The content must not be used for any commercial
|
||||
purpose, and you must not alter, transform, or build upon it.
|
||||
|
@ -113,17 +113,18 @@
|
||||
</p>
|
||||
</div>
|
||||
*}
|
||||
|
||||
{* Emails sent *}
|
||||
{* useless information when email protocol is regularly cleand-up
|
||||
{* useless information when email protocol is regularly cleand-up
|
||||
<p>
|
||||
<img src="resource2/{$opt.template.style}/images/misc/22x22-email.png" width="22" height="22" style="align: left; margin-right: 10px;" alt="{t}E-Mails sent{/t}" />
|
||||
<strong>{t 1=$emails}E-Mails sent: %1{/t}</strong>
|
||||
</p>
|
||||
*}
|
||||
<div class="buffer"> </div>
|
||||
|
||||
{* link to public profile *}
|
||||
{* now in menu
|
||||
<p>{t}This is what your profile looks like to other users:{/t} <a href="viewprofile.php?userid={$login.userid}">{t}Your public profile{/t}</a></p>
|
||||
*}
|
||||
{/if}
|
||||
|
||||
<div class="buffer"> </div>
|
||||
|
@ -55,6 +55,7 @@
|
||||
</div>
|
||||
|
||||
<table class="table">
|
||||
<tr><td class="spacer" colspan="2"></td></tr>
|
||||
<tr>
|
||||
<td valign="top">{t}Name:{/t}</td>
|
||||
<td>
|
||||
@ -83,15 +84,13 @@
|
||||
{/if}
|
||||
{/if}
|
||||
|
||||
<tr><td class="spacer" colspan="2"></td></tr>
|
||||
|
||||
<tr>
|
||||
<td align="right"><input class="checkbox" type="checkbox" name="spoiler" value="1" {if $spoilerchecked==true}checked="checked"{/if} /></td>
|
||||
<td>{t}This picture is a spoiler - dont show a thumbnail.{/t} {if $objecttype==OBJECT_CACHELOG}{t}Please use the spoiler mark also for log pictures, to prevent that they appear on log gallery pages.{/t}{/if}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td height="8px"></td>
|
||||
</tr>
|
||||
|
||||
{if $objecttype==OBJECT_CACHE}
|
||||
<tr>
|
||||
<td align="right"><input class="checkbox" type="checkbox" name="notdisplay" value="1" {if $displaychecked==false}checked="checked"{/if}></td>
|
||||
@ -103,6 +102,7 @@
|
||||
</tr>
|
||||
{/if}
|
||||
{if $action=='add'}
|
||||
<tr><td class="spacer" colspan="2"></td></tr>
|
||||
<tr>
|
||||
<td class="help" colspan="2">
|
||||
<img src="resource2/{$opt.template.style}/images/misc/hint.gif" border="0" width="15" height="11" alt="{t}Note{/t}" title="{t}Note{/t}">
|
||||
|
@ -45,3 +45,10 @@
|
||||
|
||||
{* $log != "N" *}
|
||||
{/if}
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
remove_piclinks();
|
||||
-->
|
||||
</script>
|
@ -63,7 +63,7 @@
|
||||
{/if}
|
||||
|
||||
{* the position of the following image is the anchor for enlargit activity: *}
|
||||
<a name="piclink" href="{$pictureItem.url}" onclick="enlarge(document.getElementById('pic{$pictureItem.id}'))" style="cursor:pointer">{$pictureItem.title|escape}<img id="pic{$pictureItem.id}" src="resource2/ocstyle/images/misc/empty.png" longdesc="{$pictureItem.url}" /></a>
|
||||
<a name="piclink" href="{$pictureItem.url}" onclick="enlarge(document.getElementById('pic{$pictureItem.id}'))" style="cursor:pointer">{$pictureItem.title|escape}<img id="pic{$pictureItem.id}" src="resource2/ocstyle/images/misc/empty.png" longdesc="{$pictureItem.url}"/></a>
|
||||
{if $pictureItem.spoiler}
|
||||
({t}Spoiler{/t})
|
||||
{/if}
|
||||
|
@ -34,11 +34,11 @@
|
||||
{/if}
|
||||
{/foreach}
|
||||
{* fill up remaining cells so that 2..5 pictures will not spread over container width *}
|
||||
{if $piccount<6}<td width="{$itemwidth+4}px"></td>{/if}
|
||||
{if $piccount<5}<td width="{$itemwidth+4}px"></td>{/if}
|
||||
{if $piccount<4}<td width="{$itemwidth+4}px"></td>{/if}
|
||||
{if $piccount<3}<td width="{$itemwidth+4}px"></td>{/if}
|
||||
{if $piccount<2}<td width="{$itemwidth+4}px"></td>{/if}
|
||||
{if $piccount<6}<td width="{$itemwidth}px"></td>{/if}
|
||||
{if $piccount<5}<td width="{$itemwidth}px"></td>{/if}
|
||||
{if $piccount<4}<td width="{$itemwidth}px"></td>{/if}
|
||||
{if $piccount<3}<td width="{$itemwidth}px"></td>{/if}
|
||||
{if $piccount<2}<td width="{$itemwidth}px"></td>{/if}
|
||||
</tr>
|
||||
</table>
|
||||
<div style="height:8px"></div>
|
||||
|
@ -229,15 +229,15 @@
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{* <!-- Datalicense --> *}
|
||||
{*
|
||||
<p class="sidebar-maintitle">{t}Datalicense{/t}</p>
|
||||
<div style="margin-top:20px;width:100%;text-align:center;">
|
||||
<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/de/" target="_blank"><img alt="Creative Commons Lizenzvertrag" style="border-width:0" src="http://i.creativecommons.org/l/by-nc-nd/3.0/de/88x31.png" /></a><br />{t}The www.opencaching.de content is licensed under <br /><a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/3.0/de/deed.en" target="_blank">Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Germany</a> License.{/t}
|
||||
<br />
|
||||
|
||||
</div>
|
||||
*}
|
||||
{if $license_disclaimer != ""}
|
||||
<!-- Datalicense -->
|
||||
<p class="sidebar-maintitle">{t}Datalicense{/t}</p>
|
||||
<div style="margin-top:20px;width:100%;text-align:center;">
|
||||
{$license_disclaimer}
|
||||
<br />
|
||||
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
<div class="sidebar-txtbox-noshade">
|
||||
<p class="content-txtbox-noshade-size5">
|
||||
|
@ -61,8 +61,10 @@
|
||||
{elseif $lastlogin==4}
|
||||
<td>{t}More than 12 months ago{/t}</td>
|
||||
{elseif $lastlogin==6}
|
||||
{if $license_declined}
|
||||
{if $license_actively_declined}
|
||||
<td>{t}The user account has been disabled, because the user declined the <a href="articles.php?page=impressum#datalicense">data license</a>. Cache descriptions, log texts and pictures have been deleted.{/t}</td>
|
||||
{elseif $license_passively_declined}
|
||||
<td>{t}The user account has been disabled.{/t} {t}Cache descriptions, log texts and pictures have been deleted, because the account was disabled before transition to the <a href="articles.php?page=impressum#datalicense">new data license</a>.{/t}</td>
|
||||
{else}
|
||||
<td>{t}The user account has been disabled.{/t}</td>
|
||||
{/if}
|
||||
@ -170,7 +172,6 @@
|
||||
[<a href="search.php?showresult=1&expert=0&f_inactive=0&output=HTML&sort=byname&finderid={$userid}&searchbyfinder=&logtype=3">{t}Show all{/t}</a>]
|
||||
</td>
|
||||
</tr>
|
||||
<tr><td class="spacer" colspan="2"></td></tr>
|
||||
{/if}
|
||||
|
||||
<tr>
|
||||
|
4
htdocs/util2/license/.htaccess
Normal file
4
htdocs/util2/license/.htaccess
Normal file
@ -0,0 +1,4 @@
|
||||
<FilesMatch ".*">
|
||||
Order Deny,Allow
|
||||
Deny from All
|
||||
</FilesMatch>
|
38
htdocs/util2/license/process-old-disabled-users.php
Normal file
38
htdocs/util2/license/process-old-disabled-users.php
Normal file
@ -0,0 +1,38 @@
|
||||
<?php
|
||||
/***************************************************************************
|
||||
* For license information see doc/license.txt
|
||||
*
|
||||
* Unicode Reminder メモ
|
||||
*
|
||||
* Does license-passive-diclined processing on disabled user accounts.
|
||||
* Caution: This will delete cache description and log contents and pictures!
|
||||
* Deleted texts are saved in table saved_texts.
|
||||
*
|
||||
* It is strongly recommended to do intensive test before using this script
|
||||
***************************************************************************/
|
||||
|
||||
$opt['rootpath'] = '../../';
|
||||
require_once($opt['rootpath'] . 'lib2/web.inc.php');
|
||||
require_once($opt['rootpath'] . 'lib2/logic/user.class.php');
|
||||
|
||||
$login->admin = ADMIN_USER;
|
||||
|
||||
$rs = sql("SELECT `user_id`,`username` FROM `user`
|
||||
WHERE `is_active_flag`=0 AND `data_license`=0");
|
||||
|
||||
$n = 0;
|
||||
while ($r = sql_fetch_assoc($rs))
|
||||
{
|
||||
echo "purging content of user '". $r['username'] . "'\n";
|
||||
|
||||
$user = new user($r['user_id']);
|
||||
$result = $user->disduelicense(true);
|
||||
if ($result !== true)
|
||||
die($result);
|
||||
|
||||
++$n;
|
||||
}
|
||||
sql_free_result($rs);
|
||||
|
||||
echo "purged data of $n users\n";
|
||||
?>
|
@ -8,6 +8,7 @@
|
||||
***************************************************************************/
|
||||
|
||||
require('./lib2/web.inc.php');
|
||||
require_once('./lib2/logic/user.class.php');
|
||||
require_once('./lib2/logic/useroptions.class.php');
|
||||
require_once('./lib2/logic/logpics.inc.php');
|
||||
|
||||
@ -17,6 +18,17 @@
|
||||
$userid = isset($_REQUEST['userid']) ? $_REQUEST['userid']+0 : 0;
|
||||
$allpics = isset($_REQUEST['allpics']) ? $_REQUEST['allpics']+0 : 0;
|
||||
|
||||
if ($userid == 0)
|
||||
{
|
||||
$login->verify();
|
||||
if ($login->userid != 0)
|
||||
{
|
||||
// 'show public profile' in my-profile menu
|
||||
$userid = $login->userid;
|
||||
$tpl->menuitem = MNU_MYPROFILE_PUBLIC;
|
||||
}
|
||||
}
|
||||
|
||||
$rs = sql("SELECT `user`.`username`,
|
||||
`user`.`last_login`,
|
||||
`user`.`pmr_flag`,
|
||||
@ -97,7 +109,9 @@
|
||||
$tpl->assign('recommended', sql_value("SELECT COUNT(*) FROM `cache_rating` WHERE `user_id`='&1'", 0, $userid));
|
||||
$tpl->assign('maxrecommended', floor($record['found'] * $opt['logic']['rating']['percentageOfFounds'] / 100));
|
||||
|
||||
$picstat = ($useropt->getOptValue(USR_OPT_PICSTAT) == 1);
|
||||
$user = new user($userid);
|
||||
|
||||
$picstat = ($useropt->getOptValue(USR_OPT_PICSTAT) == 1) && !$user->getLicenseDeclined();
|
||||
$tpl->assign('show_picstat', $picstat);
|
||||
if ($picstat)
|
||||
{
|
||||
@ -146,7 +160,8 @@
|
||||
$tpl->assign('lastlogin', 4);
|
||||
}
|
||||
|
||||
$tpl->assign('license_declined', $record['data_license'] == 1);
|
||||
$tpl->assign('license_actively_declined', $record['data_license'] == NEW_DATA_LICENSE_ACTIVELY_DECLINED);
|
||||
$tpl->assign('license_passively_declined', $record['data_license'] == NEW_DATA_LICENSE_PASSIVELY_DECLINED);
|
||||
$tpl->assign('pmr', $record['pmr_flag']);
|
||||
|
||||
$tpl->display();
|
||||
|
@ -21,6 +21,7 @@
|
||||
$opt['rootpath'] = '../';
|
||||
require($opt['rootpath'] . 'lib/common.inc.php');
|
||||
require($opt['rootpath'] . 'lib/charset.inc.php');
|
||||
require($opt['rootpath'] . 'lib2/const.inc.php');
|
||||
if ($error == true)
|
||||
{
|
||||
echo 'Unable to connect to database';
|
||||
@ -53,12 +54,14 @@
|
||||
$sCharset = isset($_REQUEST['charset']) ? mb_strtolower($_REQUEST['charset']) : 'iso-8859-1';
|
||||
$bXmlCData = isset($_REQUEST['cdata']) ? $_REQUEST['cdata'] : '1';
|
||||
$bAttrlist = isset($_REQUEST['attrlist']) ? $_REQUEST['attrlist'] : '0';
|
||||
$bLicense = isset($_REQUEST['license']) ? $_REQUEST['license'] : '0';
|
||||
|
||||
if ((($bOcXmlTag != '0') && ($bOcXmlTag != '1')) ||
|
||||
(($bDocType != '0') && ($bDocType != '1')) ||
|
||||
(($bXmlCData != '0') && ($bXmlCData != '1')) ||
|
||||
(($bAttrlist != '0') && ($bAttrlist != '1')) ||
|
||||
(($bXmlDecl != '0') && ($bXmlDecl != '1')))
|
||||
(($bXmlDecl != '0') && ($bXmlDecl != '1')) ||
|
||||
(($bLicense != '0') && ($bLicense != '1')))
|
||||
{
|
||||
echo 'Invalid xml options value';
|
||||
exit;
|
||||
@ -298,9 +301,56 @@
|
||||
|
||||
/* end parameter reading */
|
||||
|
||||
|
||||
function getLicenseDisclaimer($userid, $username, $userlicense, $cacheid, $language, $logdisclaimer)
|
||||
{
|
||||
global $opt, $translate, $absolute_server_URI;
|
||||
|
||||
$ltext = "";
|
||||
|
||||
if ($opt['logic']['license']['disclaimer'])
|
||||
{
|
||||
if ($userlicense != NEW_DATA_LICENSE_ACTIVELY_DECLINED &&
|
||||
$userlicense != NEW_DATA_LICENSE_PASSIVELY_DECLINED)
|
||||
{
|
||||
// © $USERNAME, www.opencaching.de, CC-BY-NC-ND, as of $DATUM
|
||||
$asof = $translate->t('as of', '', '', 0, '', 1, $language);
|
||||
|
||||
if (isset($opt['locale'][$language]['page']['license_url']))
|
||||
$lurl = $opt['locale'][$language]['page']['license_url'];
|
||||
else
|
||||
$lurl = $opt['locale']['EN']['page']['license_url'];
|
||||
if (isset($opt['locale'][$language]['format']['phpdate']))
|
||||
$df = $opt['locale'][$language]['format']['phpdate'];
|
||||
else
|
||||
$df = $opt['locale']['DE']['format']['phpdate'];
|
||||
|
||||
$purl = parse_url($absolute_server_URI);
|
||||
|
||||
$ltext =
|
||||
"© " .
|
||||
"<a href='" . $absolute_server_URI . "viewprofile.php?userid=" . $userid . "' target='_blank'>" . $username . "</a>, " .
|
||||
"<a href='" . $absolute_server_URI . "viewcache.php?cacheid=" . $cacheid . "' target='_blank'>" . $purl['host'] . "</a>, " .
|
||||
"<a href='" . $lurl . "' target='_blank'>CC BY-NC-ND</a>, " .
|
||||
$asof . " " . date($df);
|
||||
}
|
||||
|
||||
if ($logdisclaimer)
|
||||
{
|
||||
if ($ltext != "")
|
||||
$ltext .= "; ";
|
||||
$ltext .= $translate->t('all log entries © their authors', '', '', 0, '', 1, $language);
|
||||
}
|
||||
}
|
||||
|
||||
return $ltext;
|
||||
}
|
||||
|
||||
|
||||
function outputXmlFile($sessionid, $filenr, $bXmlDecl, $bOcXmlTag, $bDocType, $ziptype)
|
||||
{
|
||||
global $zip_basedir, $zip_wwwdir, $sDateformat, $sDateshort, $t1, $t2, $t3, $safemode_zip, $safemode_zip, $sCharset, $bAttrlist, $absolute_server_URI;
|
||||
global $zip_basedir, $zip_wwwdir, $sDateformat, $sDateshort, $t1, $t2, $t3, $safemode_zip, $safemode_zip, $sCharset, $bAttrlist;
|
||||
global $absolute_server_URI, $bLicense;
|
||||
global $ocxmlversion;
|
||||
// alle records aus tmpxml_* übertragen
|
||||
|
||||
@ -490,11 +540,13 @@ function outputXmlFile($sessionid, $filenr, $bXmlDecl, $bOcXmlTag, $bDocType, $z
|
||||
`cache_desc`.`language` `language`, `cache_desc`.`short_desc` `short_desc`,
|
||||
`cache_desc`.`desc` `desc`, `cache_desc`.`desc_html` `desc_html`, `cache_desc`.`hint` `hint`,
|
||||
`cache_desc`.`last_modified` `last_modified`, `caches`.`uuid` `cacheuuid`, `cache_desc`.`node` `node`,
|
||||
`cache_status`.`allow_user_view`
|
||||
`cache_status`.`allow_user_view`,
|
||||
`caches`.`user_id`, `user`.`username`, `user`.`data_license`
|
||||
FROM `tmpxml_cachedescs`
|
||||
INNER JOIN `cache_desc` ON `tmpxml_cachedescs`.`id`=`cache_desc`.`id`
|
||||
INNER JOIN `caches` ON `caches`.`cache_id`=`cache_desc`.`cache_id`
|
||||
INNER JOIN `cache_status` ON `caches`.`status`=`cache_status`.`id`');
|
||||
INNER JOIN `cache_status` ON `caches`.`status`=`cache_status`.`id`
|
||||
INNER JOIN `user` ON `user`.`user_id`=`caches`.`user_id`');
|
||||
while ($r = sql_fetch_array($rs))
|
||||
{
|
||||
$bAllowView = ($r['allow_user_view'] == 1);
|
||||
@ -507,13 +559,20 @@ function outputXmlFile($sessionid, $filenr, $bXmlDecl, $bOcXmlTag, $bDocType, $z
|
||||
fwrite($f, $t2 . '<language id="' . $r['language'] . '">' . xmlcdata($languages[$r['language']]['de']) . '</language>' . "\n");
|
||||
fwrite($f, $t2 . '<shortdesc>' . xmlcdata(($bAllowView ? $r['short_desc'] : '')) . '</shortdesc>' . "\n");
|
||||
|
||||
$desc = $r['desc'];
|
||||
if ($r['desc_html'] == 0)
|
||||
{
|
||||
$r['desc'] = mb_ereg_replace('<br />', '', $r['desc']);
|
||||
$r['desc'] = html_entity_decode($r['desc'], ENT_COMPAT, 'UTF-8');
|
||||
$desc = mb_ereg_replace('<br />', '', $desc);
|
||||
$desc = html_entity_decode($desc, ENT_COMPAT, 'UTF-8');
|
||||
}
|
||||
|
||||
fwrite($f, $t2 . '<desc html="' . (($r['desc_html'] == 1) ? '1' : '0') . '">' . xmlcdata(($bAllowView ? $r['desc'] : '')) . '</desc>' . "\n");
|
||||
|
||||
$disclaimer = getLicenseDisclaimer($r['user_id'], $r['username'], $r['data_license'], $r['cache_id'], $r['language'], true);
|
||||
if ($bLicense)
|
||||
fwrite($f, $t2 . '<license>' . xmlcdata($disclaimer) . '</license>' . "\n");
|
||||
else if ($disclaimer != "")
|
||||
$desc .= "<p><em>" . $disclaimer . "</em></p>";
|
||||
|
||||
fwrite($f, $t2 . '<desc html="' . (($r['desc_html'] == 1) ? '1' : '0') . '">' . xmlcdata(($bAllowView ? $desc : '')) . '</desc>' . "\n");
|
||||
|
||||
$r['hint'] = mb_ereg_replace('<br />', '', $r['hint']);
|
||||
$r['hint'] = html_entity_decode($r['hint'], ENT_COMPAT, 'UTF-8');
|
||||
@ -530,7 +589,9 @@ function outputXmlFile($sessionid, $filenr, $bXmlDecl, $bOcXmlTag, $bDocType, $z
|
||||
`cache_logs`.`date_created` `date_created`, `cache_logs`.`last_modified` `last_modified`,
|
||||
`cache_logs`.`uuid` `uuid`, `user`.`username` `username`, `caches`.`uuid` `cacheuuid`,
|
||||
`user`.`uuid` `useruuid`, `cache_logs`.`node` `node`, IF(NOT ISNULL(`cache_rating`.`cache_id`) AND `cache_logs`.`type`=1, 1, 0) AS `recommended`,
|
||||
`cache_status`.`allow_user_view`
|
||||
`cache_status`.`allow_user_view`,
|
||||
`user`.`data_license`,
|
||||
`caches`.`country` AS `language` /* hack */
|
||||
FROM `cache_logs`
|
||||
INNER JOIN `tmpxml_cachelogs` ON `cache_logs`.`id`=`tmpxml_cachelogs`.`id`
|
||||
INNER JOIN `user` ON `cache_logs`.`user_id`=`user`.`user_id`
|
||||
@ -553,6 +614,13 @@ function outputXmlFile($sessionid, $filenr, $bXmlDecl, $bOcXmlTag, $bDocType, $z
|
||||
fwrite($f, $t2 . '<text html="' . $r['text_html'] . '">' . xmlcdata(($bAllowView ? $r['text'] : '')) . '</text>' . "\n");
|
||||
fwrite($f, $t2 . '<datecreated>' . date($sDateformat, strtotime($r['date_created'])) . '</datecreated>' . "\n");
|
||||
fwrite($f, $t2 . '<lastmodified>' . date($sDateformat, strtotime($r['last_modified'])) . '</lastmodified>' . "\n");
|
||||
|
||||
if ($bLicense)
|
||||
{
|
||||
$disclaimer = getLicenseDisclaimer($r['user_id'], $r['username'], $r['data_license'], $r['cache_id'], $r['language'], false);
|
||||
fwrite($f, $t2 . '<license>' . xmlcdata($disclaimer) . '</license>' . "\n");
|
||||
}
|
||||
|
||||
fwrite($f, $t1 . '</cachelog>' . "\n");
|
||||
}
|
||||
mysql_free_result($rs);
|
||||
|
@ -8,8 +8,8 @@
|
||||
<!ELEMENT attrlist (attr*)>
|
||||
<!ELEMENT user (id, username, pmr, datecreated, lastmodified)>
|
||||
<!ELEMENT cache (id, userid, name, longitude, latitude, type, status, country, size, desclanguages, difficulty, terrain, rating, waypoints, datehidden, datecreated, lastmodified)>
|
||||
<!ELEMENT cachedesc (id, cacheid, language, shortdesc, desc, hint, lastmodified)>
|
||||
<!ELEMENT cachelog (id, cacheid, userid, logtype, date, text, datecreated, lastmodified)>
|
||||
<!ELEMENT cachedesc (id, cacheid, language, shortdesc, desc, hint, license, lastmodified)>
|
||||
<!ELEMENT cachelog (id, cacheid, userid, logtype, date, text, license, datecreated, lastmodified)>
|
||||
<!ELEMENT picture (id, url, title, object, attributes, datecreated, lastmodified)>
|
||||
<!ELEMENT removedobject (id, object, removeddate)>
|
||||
|
||||
|
Reference in New Issue
Block a user