Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

[Solved] And yet, another crossdomain.xml thread..

Discussion in 'Editor & General Support' started by AzorMachine, Feb 18, 2016.

  1. AzorMachine

    AzorMachine

    Joined:
    Jul 5, 2014
    Posts:
    3
    Hello everyone. I am trying to use the Google Maps Free Plugin to show a map as a texture in one of my GameObjects, but all I am getting as a result, is a error message:

    You are trying to load data from a www stream which had the following error when downloading.
    Rejected because no crossdomain.xml policy file was found

    For those about to ask, I am using localhost (set with the Internet Microsoft Service, a default configuration) and I already have a crossdomain.xml in my root, with this content:

    <?xml version="1.0"?>
    <cross-domain-policy>
    <allow-access-from domain="localhost"/>
    </cross-domain-policy>


    I don't know what I can do anymore so any suggestion will be useful :)
     
  2. toxicFork

    toxicFork

    Joined:
    Sep 15, 2011
    Posts:
    8
    AFAIK crossdomain.xml needs to be on the server that hosts the file, not on the client. What is the URL for the map texture?
     
  3. AzorMachine

    AzorMachine

    Joined:
    Jul 5, 2014
    Posts:
    3
  4. toxicFork

    toxicFork

    Joined:
    Sep 15, 2011
    Posts:
    8
    Looks like http://maps.googleapis.com/crossdomain.xml does not allow access from other domains because they may have forgotten or they disabled it themselves (ironic), that may be why it does not work.

    http://client.cors-api.appspot.com/client#?client_method=GET&client_credentials=false&server_url=http://maps.googleapis.com/crossdomain.xml&server_enable=true&server_status=200&server_credentials=false&server_tabs=remote when you open browser console and hit "Send Request" it says:

    Edit: perhaps it may be necessary to load the image through a proxy that allows cross-origin requests to its crossdomain.xml file.
     
    Last edited: Feb 18, 2016
  5. toxicFork

    toxicFork

    Joined:
    Sep 15, 2011
    Posts:
    8
  6. AzorMachine

    AzorMachine

    Joined:
    Jul 5, 2014
    Posts:
    3
    toxicFork likes this.