<% RS = Server.CreateObject("ADODB.Recordset") mbox=Request.ServerVariables('Query_String') Response.ContentType="application/rdf+xml" Response.Write('\n\n') sqlstr='SELECT b.obj FROM rdfnew b, rdfnew a WHERE b.pred="http://xmlns.com/foaf/0.1/name" and (b.subj=a.subj and a.pred="http://xmlns.com/foaf/0.1/mbox") and a.obj="'+mbox+'" limit 1' RS.Open(sqlstr,"rdf") if (!RS.EOF) { Response.Write(''+RS.Fields(0).Value+'') } try { RS.Close() } catch (e) { } sqlstr='SELECT b.obj FROM rdfnew b, rdfnew a WHERE b.pred="http://xmlns.com/foaf/0.1/nick" and (b.subj=a.subj and a.pred="http://xmlns.com/foaf/0.1/mbox") and a.obj="'+mbox+'" limit 1' RS.Open(sqlstr,"rdf") if (!RS.EOF) { Response.Write(''+RS.Fields(0).Value+'') } try { RS.Close() } catch (e) { } emails="" sqlstr='SELECT b.obj FROM rdfnew b, rdfnew a WHERE b.pred="http://xmlns.com/foaf/0.1/mbox" and (b.subj=a.subj and a.pred="http://xmlns.com/foaf/0.1/mbox") and a.obj="'+mbox+'"' RS.Open(sqlstr,"rdf") if (!RS.EOF) { emails=RS.getRows().toArray() for (i=0;i') } emails=emails.join(';') } try { RS.Close() } catch (e) { } sqlstr='SELECT distinct c.subj FROM rdfnew b, rdfnew a, rdfnew c WHERE b.pred="http://xmlns.com/foaf/0.1/knows" and (a.subj=b.subj and a.pred="http://xmlns.com/foaf/0.1/mbox") and (c.subj=b.obj and c.pred="http://xmlns.com/foaf/0.1/mbox") and a.obj="'+mbox+'"' RS.Open(sqlstr,"rdf") if (!RS.EOF) { Arr=RS.getRows().toArray() for (i=0;i\n') } else { Response.Write('\n') } } } } } try { RS.Close() } catch (e) { } sqlstr='select distinct obj from rdfnew where pred="http://xmlns.com/foaf/0.1/codepiction" and subj="'+mbox+'" and obj like "%@%"' RS.Open(sqlstr,"rdf") if (!RS.EOF) { Arr=RS.getRows().toArray() for (i=0;i\n') } else { Response.Write('\n') } emails+=';'+em } } } } try { RS.Close() } catch (e) { } sqlstr='select distinct subj from rdfnew where pred="http://xmlns.com/foaf/0.1/codepiction" and obj="'+mbox+'" and obj like "%@%"' RS.Open(sqlstr,"rdf") if (!RS.EOF) { Arr=RS.getRows().toArray() for (i=0;i\n') } else { Response.Write('\n') } } } } try { RS.Close() } catch (e) { } sqlstr='select distinct a.obj,b.subj,e.obj,f.obj from rdfnew a,rdfnew b, rdfnew c,rdfnew d,rdfnew e,rdfnew f where a.pred="http://jibbering.com/2002/3/svg/#polypath" and a.subj=b.obj and b.pred="http://jibbering.com/2002/3/svg/#hasPart" and a.subj=c.obj and c.subj=d.subj and d.pred="http://xmlns.com/foaf/0.1/mbox" and e.subj=b.subj and e.pred="http://jibbering.com/2002/3/svg/#width" and f.subj=b.subj and f.pred="http://jibbering.com/2002/3/svg/#height" and d.obj="'+mbox+'"' RS.Open(sqlstr,"rdf") if (!RS.EOF) { Arr=RS.getRows().toArray() path=Arr[0].substr(0,Arr[0].indexOf('L'))+Arr[0].split(/M[\d\.]* [\d\.]*/).join(' ') img=Arr[1] width=Arr[2] height=Arr[3] Response.Write('') Response.Write('') Response.Write(''+height+''+width+''+path+'\n') } else { sqlstr='SELECT b.obj FROM rdfnew b, rdfnew a WHERE b.pred="http://xmlns.com/foaf/0.1/depiction" and (b.subj=a.subj and a.pred="http://xmlns.com/foaf/0.1/mbox") and a.obj="'+mbox+'" limit 1' try { RS.Close() } catch (e) { } RS.Open(sqlstr,"rdf") if (!RS.EOF) { Response.Write('') Response.Write('') } else { Response.Write('') } } Response.Write('\n') %>