added embedded mode - css has to be fixed accordingly
git-svn-id: http://yolanda.mister-muffin.de/svn@177 7eef14d0-6ed0-489d-bf55-20463b2d70db
This commit is contained in:
parent
384fcb6467
commit
23f30e8259
5 changed files with 300 additions and 283 deletions
|
@ -8,8 +8,8 @@ body
|
|||
font-family: sans-serif;
|
||||
font-size: 8pt;
|
||||
font-weight: bold;
|
||||
min-width: 550px;
|
||||
margin: 2em;
|
||||
// min-width: 550px; //what is this for? we do not know which font size the user will choose so something in pixel is bullshit
|
||||
margin: 2em; //this has to be zero for embed viewing
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
#!/usr/bin/perl -w
|
||||
|
||||
use DBI;
|
||||
use Data::Dumper::Simple;
|
||||
|
||||
$database = 'yolanda';
|
||||
$dbhost = 'localhost';
|
||||
|
|
|
@ -71,6 +71,8 @@ elsif($query->url_param('title') or $query->url_param('id'))
|
|||
}
|
||||
elsif($rowcount == 1)
|
||||
{
|
||||
$page->{'embed'} = $query->param('embed') eq 'true' ? "true" : "false";
|
||||
|
||||
#if there was a single result, display the video
|
||||
my ($id, $title, $description, $publisher, $timestamp, $creator, $subject,
|
||||
$contributor, $source, $language, $coverage, $rights, $license,
|
||||
|
|
|
@ -78,6 +78,7 @@
|
|||
|
||||
<body>
|
||||
|
||||
<xsl:if test="not(//@embed='true')">
|
||||
<xsl:choose>
|
||||
<xsl:when test="string-length(//@username)=0">
|
||||
<div class="header1">
|
||||
|
@ -164,6 +165,8 @@
|
|||
<xsl:call-template name="message"/>
|
||||
</xsl:if>
|
||||
|
||||
</xsl:if>
|
||||
|
||||
<xsl:choose>
|
||||
<xsl:when test="//frontpage">
|
||||
<xsl:call-template name="frontpage"/>
|
||||
|
@ -188,6 +191,7 @@
|
|||
</xsl:when>
|
||||
</xsl:choose>
|
||||
|
||||
<xsl:if test="not(//@embed='true')">
|
||||
<div class="footer">
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
|
@ -210,6 +214,7 @@
|
|||
<xsl:value-of select="$locale_strings[@id='source_code']" />
|
||||
</a>
|
||||
</div>
|
||||
</xsl:if>
|
||||
|
||||
</body>
|
||||
|
||||
|
|
|
@ -7,10 +7,6 @@
|
|||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
>
|
||||
|
||||
<xsl:template name="video">
|
||||
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="video">
|
||||
<div class="video">
|
||||
<xsl:choose>
|
||||
|
@ -47,7 +43,14 @@
|
|||
<div>
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
<xsl:choose>
|
||||
<xsl:when test="//@embed='true'">
|
||||
<xsl:value-of select="concat(//video/rdf:RDF/cc:Work/dc:identifier, '/cortado=false&embed=true')" />
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="concat(//video/rdf:RDF/cc:Work/dc:identifier, '/cortado=false')" />
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
Watch using Browser Video Plugin
|
||||
</a>
|
||||
|
@ -68,7 +71,14 @@
|
|||
<div>
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
<xsl:choose>
|
||||
<xsl:when test="//@embed='true'">
|
||||
<xsl:value-of select="concat(//video/rdf:RDF/cc:Work/dc:identifier, '/embed=true')" />
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="//video/rdf:RDF/cc:Work/dc:identifier" />
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:attribute>
|
||||
Watch using Cortado Java Applet
|
||||
</a>
|
||||
|
@ -77,6 +87,7 @@
|
|||
</xsl:choose>
|
||||
</div>
|
||||
|
||||
<xsl:if test="not(//@embed='true')">
|
||||
<div class="videodownload">
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
|
@ -105,21 +116,21 @@
|
|||
<xsl:attribute name="href">
|
||||
<xsl:value-of select="//video/rdf:RDF/cc:License/@rdf:about" />
|
||||
</xsl:attribute>
|
||||
<!--
|
||||
<!--
|
||||
unfinished bizness
|
||||
<xsl:value-of select="@rdf:about" />
|
||||
<xsl:if test="true()">
|
||||
<img src="./images/cc/somerights.png" />
|
||||
</xsl:if>
|
||||
-->
|
||||
-->
|
||||
<xsl:for-each select="//video/rdf:RDF/cc:License/cc:permits">
|
||||
<!--
|
||||
<!--
|
||||
since we are talking about digital media here, distribution actually /is/ reproduction
|
||||
(also, i was too stupid to figure out how to test for both conditions).
|
||||
<xsl:if test="@rdf:resource = 'http://web.resource.org/cc/Reproduction'">
|
||||
<img src="./images/cc/cc-share.png" />
|
||||
</xsl:if>
|
||||
-->
|
||||
-->
|
||||
<xsl:if test="@rdf:resource = 'http://web.resource.org/cc/Distribution'">
|
||||
<img src="./images/cc/cc-share.png" />
|
||||
</xsl:if>
|
||||
|
@ -134,13 +145,13 @@
|
|||
<xsl:if test="@rdf:resource = 'http://web.resource.org/cc/ShareAlike'">
|
||||
<img src="./images/cc/cc-sharealike.png" />
|
||||
</xsl:if>
|
||||
<!--
|
||||
<!--
|
||||
source code doesn't make much sense in video context.
|
||||
still, this is preserved for potential future use.
|
||||
<xsl:if test="@rdf:resource = 'http://web.resource.org/cc/SourceCode'">
|
||||
SOURCE
|
||||
</xsl:if>
|
||||
-->
|
||||
-->
|
||||
</xsl:for-each>
|
||||
<xsl:for-each select="rdf:RDF/cc:License/cc:prohibits">
|
||||
<xsl:if test="@rdf:resource = 'http://web.resource.org/cc/CommercialUse'">
|
||||
|
@ -220,7 +231,7 @@
|
|||
</tr>
|
||||
</table>
|
||||
|
||||
<table class="referer">
|
||||
<table class="videometadata">
|
||||
<xsl:for-each select="//referers/referer">
|
||||
<tr>
|
||||
<td class="leftcell">
|
||||
|
@ -254,7 +265,7 @@
|
|||
</form>
|
||||
</div>
|
||||
</xsl:if>
|
||||
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="comments">
|
||||
|
@ -268,7 +279,7 @@
|
|||
<div class="comment">
|
||||
<a>
|
||||
<xsl:attribute name="href">
|
||||
./user/<xsl:value-of select="@username" />
|
||||
/user/<xsl:value-of select="@username" />
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="@username" />
|
||||
</a>:
|
||||
|
|
Loading…
Reference in a new issue