Guest User

Untitled

a guest
Aug 21st, 2018
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.86 KB | None | 0 0
  1. curl -H "Accept: application/rdf+xml" -L http://localhost/v0.1
  2. curl -H "Accept: application/rdf+xml" -L http://localhost/v1.0
  3.  
  4. RewriteRule ^v0.1$ https://miranda-zhang.github.io/cloud-computing-schema/v0.1/ontology/cocoon.rdf [R=308,L]
  5.  
  6. RewriteRule ^v1.0$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/ontology.xml [R=308,L]
  7.  
  8. $ curl -H "Accept: application/rdf+xml" http://localhost/v1.0
  9. % Total % Received % Xferd Average Speed Time Time Time Current
  10. Dload Upload Total Spent Left Speed
  11. 100 358 100 358 0 0 23866 0 --:--:-- --:--:-- --:--:-- 23866<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
  12. <html><head>
  13. <title>308 Permanent Redirect</title>
  14. </head><body>
  15. <h1>Permanent Redirect</h1>
  16. <p>The document has moved <a href="https://miranda-zhang.github.io/cloud-computing-schema/v1.0/index-en.html">here</a>.</p>
  17. <hr>
  18. <address>Apache/2.4.18 (Ubuntu) Server at localhost Port 80</address>
  19. </body></html>
  20.  
  21. Options +FollowSymLinks -MultiViews
  22.  
  23. AddType application/rdf+xml .rdf
  24. AddType application/rdf+xml .owl
  25. AddType text/turtle .ttl
  26. AddType application/n-triples .n3
  27. AddType application/ld+json .json
  28.  
  29. RewriteEngine On
  30.  
  31. RewriteCond %{REQUEST_FILENAME} -f [OR]
  32. RewriteCond %{REQUEST_FILENAME} -d
  33. RewriteRule .* - [L]
  34.  
  35. RewriteCond %{HTTP_ACCEPT} !application/rdf+xml.*(text/html|application/xhtml+xml)
  36. RewriteCond %{HTTP_ACCEPT} text/html [OR]
  37. RewriteCond %{HTTP_ACCEPT} application/xhtml+xml [OR]
  38. RewriteCond %{HTTP_USER_AGENT} ^Mozilla/.*
  39. RewriteRule ^v0.1/?$ https://miranda-zhang.github.io/cloud-computing-schema/v0.1/index.htm [R=308,NE,L]
  40. RewriteRule ^v1.0/?$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/index-en.html [R=308,NE,L]
  41.  
  42. RewriteCond %{HTTP_ACCEPT} application/ld+json
  43. RewriteRule ^v1.0$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/ontology.json [R=308,L]
  44.  
  45. RewriteCond %{HTTP_ACCEPT} */* [OR]
  46. RewriteCond %{HTTP_ACCEPT} application/rdf+xml
  47. RewriteRule ^v0.1$ https://miranda-zhang.github.io/cloud-computing-schema/v0.1/ontology/cocoon.rdf [R=308,L]
  48. RewriteRule ^v1.0$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/ontology.xml [R=308,L]
  49.  
  50. RewriteCond %{HTTP_ACCEPT} application/n-triples
  51. RewriteRule ^v1.0$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/ontology.nt [R=308,L]
  52.  
  53. RewriteCond %{HTTP_ACCEPT} text/turtle [OR]
  54. RewriteCond %{HTTP_ACCEPT} text/* [OR]
  55. RewriteCond %{HTTP_ACCEPT} */turtle
  56. RewriteRule ^v0.1$ https://miranda-zhang.github.io/cloud-computing-schema/v0.1/ontology/cocoon.ttl [R=308,L]
  57. RewriteRule ^v1.0$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/ontology.ttl [R=308,L]
  58.  
  59. RewriteCond %{HTTP_ACCEPT} .+
  60. RewriteRule ^$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/406.html [R=406,L]
  61.  
  62. # Default response
  63. RewriteRule ^$ https://miranda-zhang.github.io/cloud-computing-schema/v1.0/ontology.xml [R=308,L]
Add Comment
Please, Sign In to add comment