Guest User

Untitled

a guest
Oct 17th, 2018
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.83 KB | None | 0 0
  1. $http.get('http://localhost/myProject/content.json').success(function (data) {
  2. // Do stuff...
  3. }).error((data, status, headers, config) => {
  4. // Failure...
  5. });
  6.  
  7. <staticContent>
  8. <remove fileExtension=".json" />
  9. <mimeMap fileExtension=".json" mimeType="application/json" />
  10. </staticContent>
  11.  
  12. $http.get('content.json').success(function (data) {
  13. // Do stuff...
  14. }).error((data, status, headers, config) => {
  15. // Failure...
  16. });
  17.  
  18. <configuration>
  19. <system.web>
  20. <compilation debug="true" targetFramework="4.5" />
  21. <httpRuntime targetFramework="4.5" />
  22. </system.web>
  23. **<system.webServer>
  24. <staticContent>
  25. <mimeMap fileExtension=".json" mimeType="application/json" />
  26. </staticContent>
  27. </system.webServer>**
  28. </configuration>
  29.  
  30.  
  31. This works fine.. as what Erez A. Korn has said.
Add Comment
Please, Sign In to add comment