Map markers completed!

This commit is contained in:
eetnaviation
2024-04-05 16:44:03 +03:00
parent 8ca6ca501c
commit 4ff7729b24
3 changed files with 7 additions and 1 deletions

View File

@ -42,7 +42,7 @@
<script src="/socket.io/socket.io.js"></script> <script src="/socket.io/socket.io.js"></script>
<script> <script>
var socket = io();// var socket = io();
// Stuff for the map // Stuff for the map
//map = new OpenLayers.Map("demoMap");//.setView([59.4370, 24.7536], 12); //map = new OpenLayers.Map("demoMap");//.setView([59.4370, 24.7536], 12);

BIN
client/marker.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 294 B

View File

@ -31,6 +31,12 @@ app.get('/tltmap', (req, res) => {
res.sendFile(__dirname + '/client/index.html'); res.sendFile(__dirname + '/client/index.html');
}); });
app.get('/img/marker.png', (req, res) => {
var img = fs.readFileSync('./client/marker.png');
res.writeHead(200, {'Content-Type': 'image/png'});
res.end(img, 'binary');
});
server.listen(serverPort, () => { server.listen(serverPort, () => {
console.log("Apache server initalized..."); console.log("Apache server initalized...");
console.log('Server started on port', serverPort); console.log('Server started on port', serverPort);