should be used in all library code. This patch replaces all uses of "$()" in existing code. The primary reason for this is to avoid conflicts with libraries (like Prototype) which might redefine this function differently. git-svn-id: http://svn.openlayers.org/trunk/openlayers@2541 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
36 lines
1.0 KiB
HTML
36 lines
1.0 KiB
HTML
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<style type="text/css">
|
|
#map {
|
|
width: 800px;
|
|
height: 475px;
|
|
border: 1px solid black;
|
|
}
|
|
</style>
|
|
<script src="../lib/OpenLayers.js"></script>
|
|
<script type="text/javascript">
|
|
<!--
|
|
var lon = 5;
|
|
var lat = 40;
|
|
var zoom = 5;
|
|
var map, layer;
|
|
|
|
function init(){
|
|
map = new OpenLayers.Map( 'map' );
|
|
|
|
var urlArray = ["http://labs.metacarta.com/wms-c/Basic.py",
|
|
"http://monitor.metacarta.com/wms-c/Basic.py"];
|
|
layer = new OpenLayers.Layer.WMS( "OpenLayers WMS",
|
|
urlArray,
|
|
{layers: 'basic'} );
|
|
map.addLayer(layer);
|
|
map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);
|
|
}
|
|
// -->
|
|
</script>
|
|
</head>
|
|
<body onload="init()">
|
|
<div id="map"></div>
|
|
</body>
|
|
</html>
|