javascript - Three.js Loading .OBJ error in Azure but not Locally -
i using three.js webgl load .obj have problem when loading .obj in windows azure runnning windows server 2008 using google chrome browser , gives error below:
get http://websiteaddress.net/webgl/obj/test.mtl 404 (not found)
even, used original source code load .obj file has same error
and when try navigate other images file in server can preview eg: (website.net/images/test.gif) - can see test.gif image in browser
but when navigate .obj, receive error in browser: (eg : website.net/obg/test.obj)
404 - file or directory not found. resource looking might have been removed, had name changed, or temporarily unavailable.
i can view .obj locally not when put in azure! can helps me? thanks!
[solved] loading .obj (wavefront) file in windows hosting return 404 error [solved]
as working three.js , loading .obj file works great me in localhost when running files windows hosting return 404 .obj file.
so, need add lines web.config file of project root folder (if don't have file in project root folder go ahead , create one. )
web.config
<?xml version="1.0" encoding="utf-8"?> <configuration> <system.webserver> <staticcontent> <mimemap fileextension=".obj" mimetype="application/octet-stream" /> </staticcontent> </system.webserver> </configuration> place web.config correct location , enjoy :)
Comments
Post a Comment