Skip to content
Snippets Groups Projects
  • alangrafu's avatar
    3496f753
    Adding multiple queries when generating a page · 3496f753
    alangrafu authored
    Instead of creating a file for the model, create a dir (e.g.,
    foaf:Person.view.html). Inside add different files (the name doesn't
    matter). In the view file, they will be accessed as r.filename and can
    be operated as usual
    3496f753
    History
    Adding multiple queries when generating a page
    alangrafu authored
    Instead of creating a file for the model, create a dir (e.g.,
    foaf:Person.view.html). Inside add different files (the name doesn't
    matter). In the view file, they will be accessed as r.filename and can
    be operated as usual
rdfs:Class.view.html 1.10 KiB
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN"
    "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" {% for i, ns in base.ns %}xmlns:{{i}}="{{ns}}" 
    {%endfor%}version="XHTML+RDFa 1.0" xml:lang="en">
    <link href="{{base.baseUrl}}/lodspeakr/css/basic.css" rel="stylesheet" type="text/css" media="screen" />
    <head>
    <title>Page about {{base.this.value}}</title>
  </head>
  <body>
    <h1>Page about <a href='{{base.this.value}}'>{{base.this.curie}}</a></h1>
  <div>
    <h2>Instances of {{base.this.curie}}</h2>
    <ul>
    {% for row in r.instances %}
      {% if row.value.instances != null %}
        <li><a href='{{ row.value.instances }}'>{{row.curie.instances}}</a></li>
      {% endif %}
    {% endfor %}
    </ul>
    </div>
  <div>
    <h2>Superclass of {{base.this.curie}}</h2>
    <ul>
    {% for row in r.superclasses %}
      {% if row.value.class != null %}
        <li><a href='{{ row.value.class }}'>{{row.curie.class}}</a></li>
      {% endif %}
    {% endfor %}
    </ul>
    </div>
  </body>
</html>