View difference between Paste ID: d5imgsn4 and YrkdvWdu
SHOW: | | - or go back to the newest paste.
1
<!DOCTYPE html>
2
<html>
3
	<head>
4
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
	<meta http-equiv="X-UA-Compatible" content="IE=edge" />
6
	<link rel="stylesheet" type="text/css" href="Ext-3.2.1/resources/css/ext-all.css" />
7
			<style>
8
				#map-id {
9
					width: 1024px;
10
					height: 800px;
11
				}
12
				
13
			</style>
14
	<script src="/Ext-3.2.1/adapter/ext/ext-base.js"></script>
15
	<script src="/Ext-3.2.1/ext-all.js" ></script>
16
	<script src="/OpenLayers-2.12/OpenLayers.js"></script>
17
	<script src="/GeoExt/lib/GeoExt.js"></script>
18
	<script src="http://maps.google.com/maps?file=api&amp;v=2&amp;sensor=false&amp;key=*********" type="text/javascript"></script>
19
	<title>Testes</title>
20
	</head>
21
    <body>
22
        <h1>teste</h1>
23
        <div id="map-id"></div>
24
		<script>
25
		
26
			//variáveis globais
27
			var map;
28
		
29
			Ext.onReady(function() {
30
		
31
							
32
							var epsg_900913 = new OpenLayers.Projection("EPSG:900913");
33
34
							
35
							var extent_inicial = new OpenLayers.Bounds (-978394.53960205,5062062.5343474,-968610.59998291,5066954.504157);
36
37
							
38
							var opcoes = {units: 'm',projection: epsg_900913,};
39
						
40
							
41
							map = new OpenLayers.Map("map-id",opcoes);
42
							
43
							
44
							
45
							var longlat = map.getCenter();
46
							
47
							
48
							
49
							var aerial = new OpenLayers.Layer.Bing({
50
															key: "AqTGBsziZHIJYYxgivLBf0hVdrAk9mWO5cQcb8Yux8sW5M8c8opEC2lZqKR1ZZXf",
51
															type: "Aerial"
52
															});
53
							map.addLayer(aerial);
54
							
55
							
56
							
57
							map.zoomToExtent(extent_inicial);
58
							
59
							});
60
        </script>
61
    </body>
62
</html>