From cef9811dac46a9d54dab0f0d82ce5c3ae032fc7c Mon Sep 17 00:00:00 2001 From: David Robillard Date: Mon, 4 Oct 2010 18:21:08 +0000 Subject: Initial import of lv2plug.in universe. --- doc/index.php | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 doc/index.php (limited to 'doc/index.php') diff --git a/doc/index.php b/doc/index.php new file mode 100644 index 0000000..e6cdd10 --- /dev/null +++ b/doc/index.php @@ -0,0 +1,60 @@ +/
This document is content-negotiated. If you request it with Accept: application\/x-turtle<\/code> you will get the description in Turtle. Also supported: application\/rdf+xml<\/code>, application\/json<\/code>, text\/plain<\/code><\/div><\/body>/'"); + +# Return NTriples (text/plain) +} else if ($text_plain) { + header("Content-Type: text/plain"); + passthru("~/bin/rapper -q -i turtle -o ntriples ./$name.ttl"); + +# Return Turtle ontology by default +} else { + header("Content-Type: application/x-turtle"); + passthru("cat ./$name.ttl"); +} + +function accepts($type) { + global $_SERVER; + if (preg_match("/$type(;q=(\d+\.\d+))?/i", $_SERVER['HTTP_ACCEPT'], $matches)) { + return isset($matches[2]) ? $matches[2] : 1; + } else { + return 0; + } +} + +?> -- cgit v1.2.1