diff --git a/lib/OpenLayers/SingleFile.js b/lib/OpenLayers/SingleFile.js index a8b3177e52..937ef23142 100644 --- a/lib/OpenLayers/SingleFile.js +++ b/lib/OpenLayers/SingleFile.js @@ -25,7 +25,7 @@ var OpenLayers = { * {String} Path to this script */ _getScriptLocation: (function() { - var r = new RegExp("(^|(.*?\\/))(OpenLayers\.js)(\\?|$)"), + var r = new RegExp("(^|(.*?\\/))(OpenLayers.*?\\.js)(\\?|$)"), s = document.getElementsByTagName('script'), src, m, l = ""; for(var i=0, len=s.length; i + + + + + + + + diff --git a/tests/SingleFile2.html b/tests/SingleFile2.html new file mode 100644 index 0000000000..5fc9248058 --- /dev/null +++ b/tests/SingleFile2.html @@ -0,0 +1,15 @@ + + + + + + + + + diff --git a/tests/SingleFile3.html b/tests/SingleFile3.html new file mode 100644 index 0000000000..557952c233 --- /dev/null +++ b/tests/SingleFile3.html @@ -0,0 +1,15 @@ + + + + + + + + + diff --git a/tests/list-tests.html b/tests/list-tests.html index 61b19a1eea..cef96a4dd7 100644 --- a/tests/list-tests.html +++ b/tests/list-tests.html @@ -182,6 +182,9 @@
  • OpenLayers3.html
  • OpenLayers4.html
  • OpenLayersJsFiles.html
  • +
  • SingleFile1.html +
  • SingleFile2.html +
  • SingleFile3.html
  • Popup.html
  • Popup/Anchored.html
  • Popup/AnchoredBubble.html