New version of the presence plugin has been released!

Presence Plugin 1.3.0 has been released. The new version adds support for probing presence of components. This new feature will let you for instance inquire about the presence of a user using AIM/MSN/etc. by sending a presence probe to the gateway. Note that it’'s up to the component (e.g. gateway) to check for the inquirer permissions.

Download plugins from:

http://www.jivesoftware.org/wildfire/plugins.jsp

For those using the new “check for updates” feature, Wildfire checks every 48 hours for new updates so it may take a while for you to see the new version or get IM notifications.

Regarding this annoucement:

1.3.1 – July 19, 2006

  • Added support for retrieving the user’'s presence status as plain text.

I must profess my html ignorance, but how would I use this feature inside a web page.

AKA - I want the result of the ‘’&type=text’’ addition to show in my page.

Thanks

P

Well, I found one way to do this.

It may not be the best, but it works.

If there are better ways, I’'d love to see them.

P

Hi,

I did take a look at http://www.sitepoint.com/article/server-side-xml-javascript and wonder if reading and parsing the XML output would be a better way - this script seems to runs fine only for IE.

LG

<html>
     <head>
          <script>
<!--
var xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
function loadXML(xmlFile)
{ xmlDoc.async="false"; xmlDoc.onreadystatechange=verify; xmlDoc.load(xmlFile); xmlObj=xmlDoc.documentElement;
}
function verify()
{ // 0 Object is not initialized // 1 Loading object is loading data // 2 Loaded object has loaded data // 3 Data from object can be worked with // 4 Object completely initialized if (xmlDoc.readyState != 4) {
   return false; }
}
loadXML("http://domain/wildfire/plugins/presence/status?jid=foo@domain&type=xml");
alert(xmlObj.xml);
alert(xmlObj.childNodes(0).firstChild.text);
var x=xmlObj.childNodes(0).firstChild.text;
// -->
     </script>
     </head>
     <body>
     Foo
     <span id="foo"></span>
     Bar
     </body>
     <script>
<!--
document.getElementById("foo").innerHTML=x;
// -->
     </script>
</html>