Re: annotea server

"Jim Ley" <[email protected]>
Newsgroups gmane.org.w3c.annotation
Message-ID <[email protected]>

"Nathan Young" <[email protected]> wrote in message
news:UOXRTR59786FETMLC8A7411ZSPVR3X.3da4c440@inky...
>
> I've also looked at what you get when you make a request like:
>
>
http://annotest.w3.org/annotations?w3c_annotates=http%3A%2F%2Fncyoung.com
>
> Is there an easy way to get the server to return XML to my browser just
as it
> would to an annotea client?

If you use win32 IE, you can easily write a simple javascript which will
do that (any webpage)

<script>

  var xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
 function window.onload() {
  var Config=new Object()
  Config.AnnoteaServer="http://annotest.w3.org/annotations"
  Config.AnnoteaUserName="[email protected]"
  Config.AnnoteaPassword=""
  query=Config.AnnoteaServer+"?w3c_annotates=http://jibbering.com/"

xmlhttp.Open("GET",query,false,Config.AnnoteaUserName,Config.AnnoteaPassw
ord)
  xmlhttp.setRequestHeader("Accept","application/xml")
  xmlhttp.Send()
  xmltxt=xmlhttp.responseText
  document.forms[0][0].value=xmltxt
 }
</script>
<form>
<textarea style="width:500px;height:700px;"></textarea></form>

The same will work in any Mozilla (with xmlhttp object got via
http://jibbering.com/2002/4/httprequest.html , but you won't be able to
query any external sites without hoop jumping the security - IE you can
just set "access data sources across domains" to prompt/allow.

Jim.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.