groupdocs-editor / GroupDocs.Editor-for-.NET-WebForms

Moved to https://github.com/groupdocs-editor/GroupDocs.Editor-for-.NET/tree/master/Demos/WebForms
https://products.groupdocs.com/editor/net
MIT License
0 stars 2 forks source link

Failed to load module script: The server responded with a non-JavaScript MIME type of “text/html” #7

Closed atirtahirgroupdocs closed 4 years ago

atirtahirgroupdocs commented 4 years ago

This issue is raised in https://forum.groupdocs.com/t/groupdocs-editor/7835 Hi, Application works just fine when it is ran on IIS express. But the problem occurs when deploying the published file to IIS. Below is the exception that user is facing: Failed to load module script: The server responded with a non-JavaScript MIME type of "text / html". Strict MIME type checking is enforced for module scripts per HTML spec.

This is structure of virtual directory - virtual directory However, when I host application on IIS, I get this error in browser console - console

kegor commented 4 years ago

Hi @atirtahirgroupdocs, i'll try to reproduce this problem and will let you know when i'll find the solution.

kegor commented 4 years ago

@atirtahirgroupdocs, what do you think about the possibility to publish needed scripts from Resources folder as a solution?

editor_iis_0

atirtahirgroupdocs commented 4 years ago

@kegor I followed the above step. But still facing issues in console and application doesn't render. console

kegor commented 4 years ago

Hi @atirtahirgroupdocs, probably i didn't met the same result because i used the same work-around as here https://github.com/groupdocs-annotation/GroupDocs.Annotation-for-.NET-MVC/issues/47#issuecomment-534634022, what do you think about the using the same approach here?

editor_iis_1

atirtahirgroupdocs commented 4 years ago

@kegor , Its mentioned in readme file that in order to render application in browser we have to follow this "http://localhost:8080/Editor" link. But application doesn't load with this url. However, it works perfectly for "http://localhost:8080/editor/". Can you please check this at your end? It doesn't even work for "http://localhost:8080/editor". So a "/" and editor (with small e) is required in url in order to run it.

kegor commented 4 years ago

Hi @atirtahirgroupdocs, sure, i'll check this.

kegor commented 4 years ago

Hi @atirtahirgroupdocs, when you start the Editor for .NET Web Forms app in the VS (on IIS Express) there is not difference between all combinations of the url, so you just need /editor substring with/without finishing slash, with/without capital char, but on the stand-alone IIS which has a lot of options it depends on how you set up the app.