
# From http://www.w3.org/TR/swbp-vocab-pub/#recipe4
Options -MultiViews
AddType application/rdf+xml .rdf .owl
RewriteEngine On

RewriteRule string/string.owl - [L]
RewriteRule sso/sso.owl - [L]
RewriteRule ^nlp2rdf.lod2.eu.schema/stringDoc/index.html - [L]
RewriteRule ^nlp2rdf.lod2.eu.schema/ssoDoc/index.html - [L]

# Rewrite rule to serve HTML content from the vocabulary URI if requested
RewriteCond %{HTTP_ACCEPT} !application/rdf\+xml.*(text/html|application/xhtml\+xml)
RewriteCond %{HTTP_ACCEPT} text/html [OR]
RewriteCond %{HTTP_ACCEPT} application/xhtml\+xml [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mozilla/.*
RewriteRule string/(.*)$ http://nlp2rdf.lod2.eu/schema/stringDoc/index.html [R=303]

# Rewrite rule to serve HTML content from the vocabulary URI if requested
RewriteCond %{HTTP_ACCEPT} !application/rdf\+xml.*(text/html|application/xhtml\+xml)
RewriteCond %{HTTP_ACCEPT} text/html [OR]
RewriteCond %{HTTP_ACCEPT} application/xhtml\+xml [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mozilla/.*
RewriteRule sso/(.*)$ http://nlp2rdf.lod2.eu/schema/ssoDoc/index.html [R=303]


# Rewrite rule to serve RDF/XML content if requested
RewriteCond %{HTTP_ACCEPT} application/rdf\+xml
RewriteRule string/(.*)$ http://nlp2rdf.lod2.eu/schema/string/string.owl [L,R=303]

RewriteCond %{HTTP_ACCEPT} application/rdf\+xml
RewriteRule sso/(.*)$ http://nlp2rdf.lod2.eu/schema/sso/sso.owl [L,R=303]


# Choose the default response
# Rewrite rule to serve RDF/XML content by default
RewriteRule string/ http://nlp2rdf.lod2.eu/schema/string/string.owl [L,R=303]
RewriteRule sso/ http://nlp2rdf.lod2.eu/schema/sso/sso.owl [L,R=303]
