Re: .htaccess a major bottleneck to Semantic Web adoption / Was: Re: RDFa vs RDF/XML and content negotiation

Le 05/07/2009 13:54, Toby A Inkster a écrit :
> On 5 Jul 2009, at 01:52, Pierre-Antoine Champin wrote:
>
>> I guess a PHP version would not even require that .htaccess, but
>> sorry, I'm not fluent in PHP ;)
>
>
> The situation with PHP should be much the same, though I suppose web
> hosts might be more likely to set index.php in the DirectoryIndex as a
> default.

this was my intuition as well.
However, I actually have to add the DirectoryIndex directive to have 
index.php taken into account on my server.

PHP has another advantage over CGI (and WSGI): you can usually run a PHP 
script from any directory of your hosted space, while CGI are usually 
confined in a special directory.

> Anyway, I've done a quick port of your code to PHP. (I stripped out your
> connection negotiation code and replaced it with my own, as I figured
> out it would be faster to paste in the ConNeg class I'm familiar with
> rather than do line-by-line porting of the Python to PHP.) Here it is,
> same license - LGPL 3.

great :)

> We should start a repository somewhere of useful code for serving linked
> data.

I agree.

I note that your implementation uses absolute URIs for redirection. This 
has two main advantages over mine:
- this complies with the RFC (I had missed that part ;)
- this still works when you append path elements after the script name
   (which messes the relative URI in my script)

   pa

Received on Sunday, 5 July 2009 13:34:54 UTC