Search
Search titles only
By:
Search titles only
By:
Log in
Register
Search
Search titles only
By:
Search titles only
By:
Menu
Install the app
Install
Forums
New posts
All threads
Latest threads
New posts
Trending threads
Trending
Search forums
What's new
New posts
New ads
New profile posts
Latest activity
Free Ads
Latest reviews
Search ads
Members
Current visitors
New profile posts
Search profile posts
Contact us
Latest ads
Ad icon
V2ray VPN for Tunneling
hu KANNA
Updated:
Oct 22, 2026
FREE SEO Check & Google Maps Check for Sri Lankan Businesses | Web Design, Website Price Rs 14,900 |
LankaSolve
Updated:
Oct 20, 2026
ඕනම රටකට සෙට් වෙන CV එකක්
ErMurazor
Updated:
Oct 17, 2026
Hambantota
7 Acres Beachfront Land For Sell DownSouth , PerPerch Price 420 000
1024 Digital
Updated:
Oct 14, 2026
Baseus PI LITE INDOOR CAMERA
ErMurazor
Updated:
Oct 12, 2026
Electronics
Vehicles
Property
Search
Reply to thread
Forums
Computers & Internet
Software Development
need help ajex java script
Get the App
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
<blockquote data-quote="thedigit2s" data-source="post: 21026459" data-attributes="member: 242153"><p>ගොඩක් ලොකු රිප්ලයි එකක් දාලා නේද මචෝ.. තැන්ක්ස්. ඔන්න උබව රේප් කරා<img src="/styles/default/xenforo/smilies/default/wink.gif" class="smilie" loading="lazy" alt=";)" title="Wink ;)" data-shortname=";)" /> </p><p></p><p>හරි මම පහලින් මගේ කොඩ් එක පහලින් දාන්නම්. එකට setinterval funtion eka add කරලා දෙන්න. ලොකු උදවුවක් මචෝ මම කොච්චර ට්රයි කරත් හරි යන්නේ නැ. ඇත්තම කතාව මම ජවා ස්කිප්ට් ගැන මෙලෝ හසරක් දන්නේ නැ.. මට මේකේ මැප් එක ලෝඩ් වෙන්නේ නැතිව මකර්ස් ටික විතරක් ලොඩ් කරගන්නයි ඔනි</p><p></p><p><!DOCTYPE html ></p><p> <head></p><p> <meta name="viewport" content="initial-scale=1.0, user-scalable=no" /></p><p> <meta http-equiv="content-type" content="text/html; charset=UTF-8"/></p><p> <title>vtrack</title></p><p> <style></p><p> /* Always set the map height explicitly to define the size of the div</p><p> * element that contains the map. */</p><p> #map {</p><p> height: 100%;</p><p> }</p><p> /* Optional: Makes the sample page fill the window. */</p><p> html, body {</p><p> height: 100%;</p><p> margin: 0;</p><p> padding: 0;</p><p> }</p><p> </style></p><p> </head></p><p></p><p> <body></p><p> <div id="map"></div></p><p></p><p> <script></p><p> var customLabel = {</p><p> user: {</p><p> label: 'U'</p><p> },</p><p> bar: {</p><p> customer: 'C'</p><p> }</p><p> };</p><p></p><p> function initMap() {</p><p> var map = new google.maps.Map(document.getElementById('map'), {</p><p> center: new google.maps.LatLng(6.716572137030388, 79.95990197875965),</p><p> zoom: 12</p><p> });</p><p> var infoWindow = new google.maps.InfoWindow;</p><p></p><p></p><p> // Change this depending on the name of your PHP or XML file</p><p> downloadUrl('mapmarkers2.php', function(data) {</p><p> var xml = data.responseXML;</p><p> var markers = xml.documentElement.getElementsByTagName('marker');</p><p> Array.prototype.forEach.call(markers, function(markerElem) {</p><p> var name = markerElem.getAttribute('name');</p><p> var address = markerElem.getAttribute('address');</p><p> var type = markerElem.getAttribute('type');</p><p> var point = new google.maps.LatLng(</p><p> parseFloat(markerElem.getAttribute('lat')),</p><p> parseFloat(markerElem.getAttribute('lng')));</p><p></p><p> var infowincontent = document.createElement('div');</p><p> var strong = document.createElement('strong');</p><p> strong.textContent = name</p><p> infowincontent.appendChild(strong);</p><p> infowincontent.appendChild(document.createElement('br'));</p><p></p><p> var text = document.createElement('text');</p><p> text.textContent = address</p><p> infowincontent.appendChild(text);</p><p> var icon = customLabel[type] || {};</p><p> var marker = new google.maps.Marker({</p><p> map: map,</p><p> position: point,</p><p> label: type</p><p> });</p><p> marker.addListener('click', function() {</p><p> infoWindow.setContent(infowincontent);</p><p> infoWindow.open(map, marker);</p><p> });</p><p> </p><p> </p><p> });</p><p></p><p> });</p><p> }</p><p></p><p></p><p></p><p> function downloadUrl(url, callback) {</p><p></p><p> var request = window.ActiveXObject ?</p><p> new ActiveXObject('Microsoft.XMLHTTP') :</p><p> new XMLHttpRequest;</p><p></p><p> request.onreadystatechange = function() {</p><p> if (request.readyState == 4) {</p><p> </p><p> request.onreadystatechange = doNothing;</p><p> callback(request, request.status);</p><p> }</p><p> };</p><p></p><p> request.open('GET', url, true);</p><p> request.send(null);</p><p> }</p><p> </p><p> function doNothing() {}</p><p> </script></p><p> <script async defer</p><p> src="https://maps.googleapis.com/maps/api/js?key=&callback=initMap"></p><p> </script></p><p> </body></p><p></html></p></blockquote><p></p>
[QUOTE="thedigit2s, post: 21026459, member: 242153"] ගොඩක් ලොකු රිප්ලයි එකක් දාලා නේද මචෝ.. තැන්ක්ස්. ඔන්න උබව රේප් කරා;) හරි මම පහලින් මගේ කොඩ් එක පහලින් දාන්නම්. එකට setinterval funtion eka add කරලා දෙන්න. ලොකු උදවුවක් මචෝ මම කොච්චර ට්රයි කරත් හරි යන්නේ නැ. ඇත්තම කතාව මම ජවා ස්කිප්ට් ගැන මෙලෝ හසරක් දන්නේ නැ.. මට මේකේ මැප් එක ලෝඩ් වෙන්නේ නැතිව මකර්ස් ටික විතරක් ලොඩ් කරගන්නයි ඔනි <!DOCTYPE html > <head> <meta name="viewport" content="initial-scale=1.0, user-scalable=no" /> <meta http-equiv="content-type" content="text/html; charset=UTF-8"/> <title>vtrack</title> <style> /* Always set the map height explicitly to define the size of the div * element that contains the map. */ #map { height: 100%; } /* Optional: Makes the sample page fill the window. */ html, body { height: 100%; margin: 0; padding: 0; } </style> </head> <body> <div id="map"></div> <script> var customLabel = { user: { label: 'U' }, bar: { customer: 'C' } }; function initMap() { var map = new google.maps.Map(document.getElementById('map'), { center: new google.maps.LatLng(6.716572137030388, 79.95990197875965), zoom: 12 }); var infoWindow = new google.maps.InfoWindow; // Change this depending on the name of your PHP or XML file downloadUrl('mapmarkers2.php', function(data) { var xml = data.responseXML; var markers = xml.documentElement.getElementsByTagName('marker'); Array.prototype.forEach.call(markers, function(markerElem) { var name = markerElem.getAttribute('name'); var address = markerElem.getAttribute('address'); var type = markerElem.getAttribute('type'); var point = new google.maps.LatLng( parseFloat(markerElem.getAttribute('lat')), parseFloat(markerElem.getAttribute('lng'))); var infowincontent = document.createElement('div'); var strong = document.createElement('strong'); strong.textContent = name infowincontent.appendChild(strong); infowincontent.appendChild(document.createElement('br')); var text = document.createElement('text'); text.textContent = address infowincontent.appendChild(text); var icon = customLabel[type] || {}; var marker = new google.maps.Marker({ map: map, position: point, label: type }); marker.addListener('click', function() { infoWindow.setContent(infowincontent); infoWindow.open(map, marker); }); }); }); } function downloadUrl(url, callback) { var request = window.ActiveXObject ? new ActiveXObject('Microsoft.XMLHTTP') : new XMLHttpRequest; request.onreadystatechange = function() { if (request.readyState == 4) { request.onreadystatechange = doNothing; callback(request, request.status); } }; request.open('GET', url, true); request.send(null); } function doNothing() {} </script> <script async defer src="https://maps.googleapis.com/maps/api/js?key=&callback=initMap"> </script> </body> </html> [/QUOTE]
Insert quotes…
Verification
Hath warak paha keeyada? (hatha wadikireema paha)
Post reply
Top
Bottom