<% output=[]; RS = Server.CreateObject("ADODB.Recordset"); obj=(Request.QueryString('obj')+'').replace(new RegExp("'","gim"),"-"); //' RSC=new ActiveXObject("ADODB.Connection"); RSC.Open("rdf"); Type="http://jibbering.com/foaf/jim.rdf#Unknown" Name="Unknown" if (obj=='undefined' || obj=='') { obj="_:director1_"; } sqlstr="select obj from theyrule where subj='"+obj+"' and pred='http://www.w3.org/1999/02/22-rdf-syntax-ns#type' limit 1"; RS.Open(sqlstr,RSC); if (!RS.EOF) { Type=RS.Fields(0).Value; } sqlstr="select obj from theyrule where subj='"+obj+"' and pred='http://xmlns.com/foaf/0.1/name' limit 1"; try { RS.Close() } catch (E) {}; RS.Open(sqlstr,RSC); if (!RS.EOF) { Name=RS.Fields(0).Value; } if (Type=="http://xmlns.com/foaf/corp#Company") { // It's a company queryObj=obj.replace(/_$/,"board_"); query2="subj"; query1="obj"; pred="member"; otherType="http://xmlns.com/foaf/0.1/Person" start=""; end=""; } else { // It's a Person queryObj=obj; query2="obj"; query1="subj"; pred="memberOf"; start=""; otherType="http://xmlns.com/foaf/corp#Company"; end=""; } sqlstr="select "+query1+" from theyrule where "+query2+"='"+queryObj+"' and pred='http://xmlns.com/foaf/corp#member'"; //Response.Write('<-- '+sqlstr+' -->'); try { RS.Close() } catch (E) {}; RS.Open(sqlstr,RSC); if (!RS.EOF) { objects=RS.getRows().toArray(); for (i=0;i'); } } Response.ContentType="text/xml"; %> <% Response.Write(start); Response.Write(''+obj+''); Response.Write(''+Name+''); Response.Write(output.join('')); Response.Write(end); %>