3908: marked oconlies in map popups
This commit is contained in:
@ -198,7 +198,8 @@ function output_cachexml($sWaypoint)
|
|||||||
`caches`.`date_created`,
|
`caches`.`date_created`,
|
||||||
IFNULL(`stat_caches`.`toprating`, 0) AS `toprating`,
|
IFNULL(`stat_caches`.`toprating`, 0) AS `toprating`,
|
||||||
IF(`caches`.`user_id`='&1', 1, 0) AS `owner`,
|
IF(`caches`.`user_id`='&1', 1, 0) AS `owner`,
|
||||||
`user`.`username`, `user`.`user_id`
|
`user`.`username`, `user`.`user_id`,
|
||||||
|
IF(`caches_attributes`.`attrib_id` IS NULL, 0, 1) AS `oconly`
|
||||||
FROM `caches`
|
FROM `caches`
|
||||||
INNER JOIN `cache_type` ON `caches`.`type`=`cache_type`.`id`
|
INNER JOIN `cache_type` ON `caches`.`type`=`cache_type`.`id`
|
||||||
INNER JOIN `cache_status` ON `caches`.`status`=`cache_status`.`id`
|
INNER JOIN `cache_status` ON `caches`.`status`=`cache_status`.`id`
|
||||||
@ -211,6 +212,7 @@ function output_cachexml($sWaypoint)
|
|||||||
LEFT JOIN `sys_trans_text` AS `trans_type_text` ON `trans_type`.`id`=`trans_type_text`.`trans_id` AND `trans_type_text`.`lang`='&2'
|
LEFT JOIN `sys_trans_text` AS `trans_type_text` ON `trans_type`.`id`=`trans_type_text`.`trans_id` AND `trans_type_text`.`lang`='&2'
|
||||||
LEFT JOIN `sys_trans` AS `trans_size` ON `cache_size`.`trans_id`=`trans_size`.`id` AND `cache_size`.`name`=`trans_size`.`text`
|
LEFT JOIN `sys_trans` AS `trans_size` ON `cache_size`.`trans_id`=`trans_size`.`id` AND `cache_size`.`name`=`trans_size`.`text`
|
||||||
LEFT JOIN `sys_trans_text` AS `trans_size_text` ON `trans_size`.`id`=`trans_size_text`.`trans_id` AND `trans_size_text`.`lang`='&2'
|
LEFT JOIN `sys_trans_text` AS `trans_size_text` ON `trans_size`.`id`=`trans_size_text`.`trans_id` AND `trans_size_text`.`lang`='&2'
|
||||||
|
LEFT JOIN `caches_attributes` ON `caches_attributes`.`cache_id`=`caches`.`cache_id` AND `caches_attributes`.`attrib_id`=6
|
||||||
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
|
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')",
|
||||||
$login->userid, $opt['template']['locale'], $sWaypoint);
|
$login->userid, $opt['template']['locale'], $sWaypoint);
|
||||||
@ -249,6 +251,7 @@ function output_cachexml($sWaypoint)
|
|||||||
echo 'found="' . xmlentities(($nFoundCount>0) ? 1 : 0) . '" ';
|
echo 'found="' . xmlentities(($nFoundCount>0) ? 1 : 0) . '" ';
|
||||||
echo 'notfound="' . xmlentities(($nNotFoundCount>0) ? 1 : 0) . '" ';
|
echo 'notfound="' . xmlentities(($nNotFoundCount>0) ? 1 : 0) . '" ';
|
||||||
echo 'attended="' . xmlentities(($nAttendedCount>0) ? 1 : 0) . '" ';
|
echo 'attended="' . xmlentities(($nAttendedCount>0) ? 1 : 0) . '" ';
|
||||||
|
echo 'oconly="' . xmlentities($rCache['oconly']) . '" ';
|
||||||
echo 'owner="' . xmlentities($rCache['owner']) . '" ';
|
echo 'owner="' . xmlentities($rCache['owner']) . '" ';
|
||||||
echo 'username="' . xmlentities($rCache['username']) . '" ';
|
echo 'username="' . xmlentities($rCache['username']) . '" ';
|
||||||
echo 'userid="' . xmlentities($rCache['user_id']) . '" />' . "\n";
|
echo 'userid="' . xmlentities($rCache['user_id']) . '" />' . "\n";
|
||||||
|
BIN
htdocs/resource2/ocstyle/images/misc/is_oconly_small.png
Normal file
BIN
htdocs/resource2/ocstyle/images/misc/is_oconly_small.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.2 KiB |
@ -775,6 +775,7 @@
|
|||||||
var bFound = aCaches[0].getAttribute("found");
|
var bFound = aCaches[0].getAttribute("found");
|
||||||
var bNotFound = aCaches[0].getAttribute("notfound");
|
var bNotFound = aCaches[0].getAttribute("notfound");
|
||||||
var bAttended = aCaches[0].getAttribute("attended");
|
var bAttended = aCaches[0].getAttribute("attended");
|
||||||
|
var bOconly = aCaches[0].getAttribute("oconly");
|
||||||
var bOwner = aCaches[0].getAttribute("owner");
|
var bOwner = aCaches[0].getAttribute("owner");
|
||||||
var sUsername = aCaches[0].getAttribute("username");
|
var sUsername = aCaches[0].getAttribute("username");
|
||||||
var nUserId = aCaches[0].getAttribute("userid");
|
var nUserId = aCaches[0].getAttribute("userid");
|
||||||
@ -786,8 +787,10 @@
|
|||||||
sHtml += "<tr><td> </td><td> </td></tr>";
|
sHtml += "<tr><td> </td><td> </td></tr>";
|
||||||
}
|
}
|
||||||
|
|
||||||
sHtml += "<tr><td><img src='resource2/ocstyle/images/cacheicon/16x16-" + nTypeId + ".gif' alt='" + xmlentities(sTypeText) + "' title='" + xmlentities(sTypeText) + "' /> <a href='viewcache.php?wp=" + encodeURI(sWPOC) + "' target='_blank'><font size='2'>" + xmlentities(sName) + "</font></a></td><td align='right' width='60px'><font size='2'><b>" + xmlentities(sWPOC) + "</b></font></td></tr>";
|
sHtml += "<tr><td";
|
||||||
sHtml += "<tr><td colspan='2'>{/literal}{t escape=js}by{/t}{literal} <a href='viewprofile.php?userid=" + encodeURI(nUserId) + "' target='_blank'>" + xmlentities(sUsername) + "</a></td></tr>";
|
if (name.length <= 60) sHtml += " style='white-space: nowrap;'";
|
||||||
|
sHtml += "><img src='resource2/ocstyle/images/cacheicon/16x16-" + nTypeId + ".gif' alt='" + xmlentities(sTypeText) + "' title='" + xmlentities(sTypeText) + "' /> <a href='viewcache.php?wp=" + encodeURI(sWPOC) + "' target='_blank'><font size='2'>" + xmlentities(sName) + "</font></a></td><td align='right' width='60px'><font size='2'><b>" + xmlentities(sWPOC) + "</b></font></td></tr>";
|
||||||
|
sHtml += "<tr><td>{/literal}{t escape=js}by{/t}{literal} <a href='viewprofile.php?userid=" + encodeURI(nUserId) + "' target='_blank'>" + xmlentities(sUsername) + "</a></td><td align='right'>" + (bOconly==1 ? "<img src='resource2/ocstyle/images/misc/is_oconly_small.png' alt='OConly' title='OConly' />" : "") + "</td></tr>";
|
||||||
sHtml += "<tr><td colspan='2'>" + xmlentities(sTypeText) + " (" + xmlentities(sSizeText) + ") {t escape=js}D/T:{/t} " + parseFloat(nDifficulty).toFixed(1) + "/" + parseFloat(nTerrain).toFixed(1) + "</td></tr>";
|
sHtml += "<tr><td colspan='2'>" + xmlentities(sTypeText) + " (" + xmlentities(sSizeText) + ") {t escape=js}D/T:{/t} " + parseFloat(nDifficulty).toFixed(1) + "/" + parseFloat(nTerrain).toFixed(1) + "</td></tr>";
|
||||||
sHtml += "<tr><td colspan='2'>{/literal}{t escape=js}Listed since:{/t}{literal} " + xmlentities(sListedSince) + "</td></tr>";
|
sHtml += "<tr><td colspan='2'>{/literal}{t escape=js}Listed since:{/t}{literal} " + xmlentities(sListedSince) + "</td></tr>";
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user