Răsfoiți Sursa

Fix MIME type request in sample code. Fixes #3292

rawgithub.com and raw.github.com serve files with different MIME types.  Chrome doesn't treat the MIME type served from raw.github.com as executable JavaScript, so the sample code provided in Creating-a-scene.html fails.  This patch changes the requested URL to make the sample code run correctly in all browsers.
Jeremy Kahn 12 ani în urmă
părinte
comite
c22b7784c0
1 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 2 2
      docs/manual/introduction/Creating-a-scene.html

+ 2 - 2
docs/manual/introduction/Creating-a-scene.html

@@ -27,7 +27,7 @@
 				<style>canvas { width: 100%; height: 100% }</style>
 			</head>
 			<body>
-				<script src="https://raw.github.com/mrdoob/three.js/master/build/three.js"></script>
+				<script src="https://rawgithub.com/mrdoob/three.js/master/build/three.js"></script>
 				<script>
 					// Our Javascript will go here.
 				</script>
@@ -121,7 +121,7 @@
 				<style>canvas { width: 100%; height: 100% }</style>
 			</head>
 			<body>
-				<script src="https://raw.github.com/mrdoob/three.js/master/build/three.js"></script>
+				<script src="https://rawgithub.com/mrdoob/three.js/master/build/three.js"></script>
 				<script>
 					var scene = new THREE.Scene();
 					var camera = new THREE.PerspectiveCamera(75, window.innerWidth/window.innerHeight, 0.1, 1000);