Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[protege-discussion] What MIME type does Protege asks when reading ontology from given URI?

Nikola Milikic nikola.milikic at gmail.com
Mon Jan 24 14:34:25 PST 2011


Hi Timothy,

Thanks for the prompt response.

I am guessing that you are using Protege 3.  I suspect that if you try
> Protege 4.1 this will work.


Actually, I was using 4.1 in the first place.

But, I've realized now what I was doing wrong. First mistake was a newbie's
one: I didn't escape the + sign in application/rdf+xml, so it should have
been written

RewriteCond %{HTTP_ACCEPT} application/rdf\+xml


And my second mistake was that I was supposed to first serve requests for *
application/rdf\+xml* and then for *application/xml.* I suppose Protege
accepts both of them, so if *application/xml* is served first, Protege would
accept it.

I just wanted to share my solution here in case somebody else gets stuck on
the same issue.

Thanks again for the help and best wishes with the project!

Regards,
Nikola Milikic

Email: nikola.milikic at gmail.com
URL:   nikola.milikic.info


On Mon, Jan 24, 2011 at 9:08 PM, Timothy Redmond <tredmond at stanford.edu>wrote:

>
>  One of the agents I would like to be able to properly fetch the ontology
> is Protege (in .rdf form, of course). In my .htaccess file, I stated that if
> an agent doesn't asks for: *
> text/plain, text/html, text/xml, application/xml,*
> *, application/xhtml+xml*, i.e. sends '*Accept: application/rdf+xml*', it
> will be served .rdf file. When I curl it from the console with a switch *-H
> "Accept: application/rdf+xml"*, it works fine. But if I try to read the
> ontology from Protege, it always reads the html form of the ontology (the
> spec), not the .rdf file.
>
>
> I am guessing that you are using Protege 3.  I suspect that if you try
> Protege 4.1 this will work.  There is some code in the OWL api that
> specifically handles the cases that you mention.
>
> -Timothy
>
>
>
> On 01/24/2011 10:14 AM, Nikola Milikic wrote:
>
> Hi all,
>
>  I'm trying to set up my ontology to be available online, alongside with
> it's specification.
>
>  Following '*Configuring Apache HTTP Server for RDFS/OWL Ontologies
> Cookbook*' [1] I want to set up my server to be able to serve different
> types of content for different agents (which actually just asks for
> different 'Accept' attribute in the HTTP header).
>
>  One of the agents I would like to be able to properly fetch the ontology
> is Protege (in .rdf form, of course). In my .htaccess file, I stated that if
> an agent doesn't asks for: *
> text/plain, text/html, text/xml, application/xml,*
> *, application/xhtml+xml*, i.e. sends '*Accept: application/rdf+xml*', it
> will be served .rdf file. When I curl it from the console with a switch *-H
> "Accept: application/rdf+xml"*, it works fine. But if I try to read the
> ontology from Protege, it always reads the html form of the ontology (the
> spec), not the .rdf file.
>
>  Finally, my question is, how does the HTTP header looks like when Protege
> is reading an ontology given the URI of the ontology (from the Welcome
> Screen in Protege)? What is the MIME type in the HTTP Request header's
> 'Accept' attribute? Or, if somebody has had a similar problem in setting the
> server in similar fashion, I would appreciate assistance.
>
>
>  [1]
> http://www.w3.org/2001/sw/BestPractices/VM/http-examples/2005-11-18/#recipe4
>
> Best regards,
> Nikola Milikic
>
> Email: nikola.milikic at gmail.com
> URL:   nikola.milikic.info
>
>
> _______________________________________________
> protege-discussion mailing listprotege-discussion at lists.stanford.eduhttps://mailman.stanford.edu/mailman/listinfo/protege-discussion
>
> Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03
>
>
>
> _______________________________________________
> protege-discussion mailing list
> protege-discussion at lists.stanford.edu
> https://mailman.stanford.edu/mailman/listinfo/protege-discussion
>
> Instructions for unsubscribing:
> http://protege.stanford.edu/doc/faq.html#01a.03
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/protege-discussion/attachments/20110124/1b557cd0/attachment.html>


More information about the protege-discussion mailing list