# OpenLayers Script Protocol Example

# Script Protocol

protocol, script, cross origin, advanced

Demonstrates the use of a script protocol for making feature requests cross origin.

In cases where a service returns serialized features and accepts a named callback (e.g. http://example.com/features.json?callback=foo), the script protocol can be used to read features without being restricted by the same origin policy.

View the cross-origin.js source to see how this is done