-
Notifications
You must be signed in to change notification settings - Fork 21
Expand file tree
/
Copy pathREADME
More file actions
20 lines (12 loc) · 694 Bytes
/
Copy pathREADME
File metadata and controls
20 lines (12 loc) · 694 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Saving a Leaflet Map to a PNG Example using Javascript and PHP
=============================================================================
This is an example of taking a Leaflet map and saving it to a PNG.
To run the source example unzip the files into a directory on your webserver.
Make sure to CHMOD the savedMaps directory 777.
Load it up in a web browser and click the "Save to PNG button". Give it a few seconds.
=============================================================================
Many thanks to:
html2canvas by Niklas von Hertzen
https://github.com/niklasvh/html2canvas
Jamund Ferguson
http://j-query.blogspot.com/2011/02/save-base64-encoded-canvas-image-to-png.html