diff --git a/htroot/api/yacydoc.htm b/htroot/api/yacydoc.htm new file mode 100644 index 000000000..8089692e9 --- /dev/null +++ b/htroot/api/yacydoc.htm @@ -0,0 +1,3 @@ +{ + "result": "#[taglinks]#" +} \ No newline at end of file diff --git a/htroot/api/yacydoc.java b/htroot/api/yacydoc.java index 8bd2ac332..2ddfcdfd5 100644 --- a/htroot/api/yacydoc.java +++ b/htroot/api/yacydoc.java @@ -26,6 +26,7 @@ // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA import java.net.MalformedURLException; +import java.util.Iterator; import net.yacy.cora.date.ISO8601Formatter; import net.yacy.cora.document.ASCII; @@ -42,6 +43,7 @@ import net.yacy.search.index.Segment; import net.yacy.search.index.Segments; import com.hp.hpl.jena.rdf.model.Model; +import com.hp.hpl.jena.rdf.model.RDFNode; import de.anomic.server.serverObjects; import de.anomic.server.serverSwitch; @@ -138,6 +140,19 @@ public class yacydoc { String rdf = JenaTripleStore.getRDFByModel(model); prop.putXML("triples", rdf); prop.put("rdf", header.fileType() == FileType.XML ? rdf : ""); + + + String references = ""; + Iterator t = JenaTripleStore.getObjects("http://yacy.net/url#"+urlhash, "http://purl.org/dc/terms/references"); + + while (t.hasNext()) { + RDFNode r = t.next(); + references += r.toString()+","; + } + + Log.logInfo ("TRIPLESTORE", references); + + prop.put("taglinks", references); // return rewrite properties return prop; diff --git a/htroot/env/templates/jqueryheader.template b/htroot/env/templates/jqueryheader.template index c064819e2..e93f8bad3 100644 --- a/htroot/env/templates/jqueryheader.template +++ b/htroot/env/templates/jqueryheader.template @@ -9,4 +9,5 @@ + diff --git a/htroot/interaction_elements/Tag_part.html b/htroot/interaction_elements/Tag_part.html index 69622945b..f94496982 100644 --- a/htroot/interaction_elements/Tag_part.html +++ b/htroot/interaction_elements/Tag_part.html @@ -28,6 +28,8 @@ color: #5a346e;