From 3351b8cd934491d4db84a12d7393332876f5b574 Mon Sep 17 00:00:00 2001 From: Tobias Grubenmann Date: Thu, 11 Apr 2019 11:12:25 +0800 Subject: [PATCH] Added JSON support --- timebank/.htaccess | 3 ++- timebank/0.1/.htaccess | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/timebank/.htaccess b/timebank/.htaccess index 9a99db8df..c2df042ce 100644 --- a/timebank/.htaccess +++ b/timebank/.htaccess @@ -6,7 +6,8 @@ Options -MultiViews AddType application/rdf+xml .rdf AddType application/rdf+xml .owl AddType text/turtle .ttl -AddType application/n-triples .n3 +AddType application/n-triples .nt +AddType application/ld+json .json # Rewrite engine setup RewriteEngine On diff --git a/timebank/0.1/.htaccess b/timebank/0.1/.htaccess index 93e4c16b7..f0e2ad0b2 100644 --- a/timebank/0.1/.htaccess +++ b/timebank/0.1/.htaccess @@ -7,6 +7,7 @@ AddType application/rdf+xml .rdf AddType application/rdf+xml .owl AddType text/turtle .ttl AddType application/n-triples .nt +AddType application/ld+json .json # Rewrite engine setup RewriteEngine On @@ -33,6 +34,10 @@ RewriteCond %{HTTP_ACCEPT} text/\* [OR] RewriteCond %{HTTP_ACCEPT} \*/turtle RewriteRule ^(.*)$ https://tobiasgrubenmann.github.io/Ontologies/Timebank/ontology.ttl [R=303,L] +# Rewrite rule to serve JSON-LD content from the vocabulary URI if requested +RewriteCond %{HTTP_ACCEPT} application/ld\+json +RewriteRule ^$ https://tobiasgrubenmann.github.io/Ontologies/Timebank/ontology.json [R=303,L] + # Choose the default response # ---------------------------