Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Adding crossdomain XML, addressing Flash

  • Loading branch information...
commit a41c358e32d357e526d4327bcfa3359d51ef4259 1 parent eddb7af
@tmcw tmcw authored
Showing with 11 additions and 0 deletions.
  1. +8 −0 servers/Tile.bones
  2. +3 −0  templates/CrossdomainXML._
View
8 servers/Tile.bones
@@ -28,9 +28,17 @@ server = Bones.Server.extend({
this.get('/:version(1|2).0.0/:tileset/layer.json', this.layer);
this.get('/download/:tileset.mbtiles', this.download);
+
+ this.get('/crossdomain.xml', this.crossdomainXML);
this.get('/status', this.status);
},
+ crossdomainXML: function(req, res, next) {
+ res.send(templates.CrossdomainXML(), {
+ 'Content-Type': 'text/x-cross-domain-policy'
+ }, 200);
+ },
+
// Basic route for checking the health of the server.
status: function(req, res, next) {
res.send('TileStream', 200);
View
3  templates/CrossdomainXML._
@@ -0,0 +1,3 @@
+<cross-domain-policy>
+ <allow-access-from domain="*"/>
+</cross-domain-policy>
Please sign in to comment.
Something went wrong with that request. Please try again.