Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F1082651
yp_map.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
3 KB
Subscribers
None
yp_map.php
View Options
<?php
/**
* Created by PhpStorm.
* User: OBDEV-02
* Date: 25/4/2560
* Time: 18:44
*/
if
(
isset
(
$_GET
[
"latitude"
])
||
isset
(
$_POST
[
"latitude"
])){
$latitude
=
isset
(
$_GET
[
"latitude"
])
?
$_GET
[
"latitude"
]
:
$_POST
[
"latitude"
];
}
if
(
isset
(
$_GET
[
"longitude"
])
||
isset
(
$_POST
[
"longitude"
])){
$longitude
=
isset
(
$_GET
[
"longitude"
])
?
$_GET
[
"longitude"
]
:
$_POST
[
"longitude"
];
}
if
(
isset
(
$_GET
[
"height"
])
||
isset
(
$_POST
[
"height"
])){
$height
=
isset
(
$_GET
[
"height"
])
?
$_GET
[
"height"
]
:
$_POST
[
"height"
];
}
else
{
$height
=
"430"
;
}
if
(
isset
(
$_GET
[
"width"
])
||
isset
(
$_POST
[
"width"
])){
$width
=
isset
(
$_GET
[
"width"
])
?
$_GET
[
"width"
]
:
$_POST
[
"width"
];
}
else
{
$width
=
"500"
;}
//$height -= 30;
$LandingPage_URL
=
"http://landingpage.yellowpages.co.th"
;
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<title>แผนที่</title>
<?
if
(
$latitude
||
$longitude
)
{
?>
<!-- Google Map API -->
<script src="//code.jquery.com/jquery-1.11.0.min.js"></script>
<script>var jQuery_1_1_3 = $.noConflict(true);</script>
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDC0YkSE1985EKtSMMlczky7zORmSQtn6Y&language=th"></script>
<style type="text/css">
#map-canvas{
/*width: "
<?
=
$height
?>
px";
height: "
<?
=
$width
?>
"; */
width: "
<?
=
$width
?>
px";
height: "
<?
=
$height
?>
";
}
</style>
<script type="text/javascript">
var map;
// jQuery_1_1_3(".zoom", window.parent.document).hide();
function initialize(){
// alert("Tab Show Arealdy");
google.maps.event.trigger(map, 'resize');
var center = new google.maps.LatLng(
<?
=
$latitude
?>
,
<?
=
$longitude
?>
);
map.setCenter(center);
//jQuery_1_1_3("#map-canvas").after(btt);<a target='_blank' href='https://www.google.co.th/maps/search/
<?
=
$latitude
?>
,
<?
=
$longitude
?>
'>Zoom</a>");
}
function loadMap()
{
// alert("Load Map");
// alert(jQuery_1_1_3('ul#company-tab li').length);
jQuery_1_1_3("#mapClick").remove();
jQuery_1_1_3( "#map-canvas" ).animate({
height:
<?
=
$height
?>
}, 200, function() {
initialize();
});
var mapOptions = {
zoom: 15,
center: new google.maps.LatLng(
<?
=
$latitude
?>
,
<?
=
$longitude
?>
)
};
map = new google.maps.Map(document.getElementById('map-canvas'),
mapOptions);
var marker = new google.maps.Marker({
position: new google.maps.LatLng(
<?
=
$latitude
?>
,
<?
=
$longitude
?>
),
map: map,
icon:"
<?
=
$LandingPage_URL
?>
/images/map_pointer.png"
});
}
</script>
</head>
<style type="text/css">
*{padding:0;margin:0;}
</style>
<body
<?
if
(
$_GET
[
'bypass'
])
echo
" onload='loadMap();' "
;
?>
<div id="map-canvas">
<?
if
(!
$_GET
[
'bypass'
])
{
?>
<a id="mapClick" href="#" onclick="loadMap(); return false;">
<img class="google_map_mobile"width="100%" src="/modules/typ/typ_profile/digital-map-610x340.jpg">
</a>
<?
}
?>
</div>
</body>
</html>
<?
}
?>
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Mon, Dec 23, 8:21 AM (18 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
193556
Attached To
rPF typ_profile
Event Timeline
Log In to Comment