I tried two more ways of hiding the account box unless a user is logged in:
I tried two more ways of hiding only the My Account box unless a user is
logged in:
In Classic.xsl:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet
xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
xmlns:dri="http://di.tamu.edu/DRI/1.0/"
xmlns:mets="http://www.loc.gov/METS/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
xmlns:mods="http://www.loc.gov/mods/v3"
xmlns:xlink="http://www.w3.org/TR/xlink/"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:import href="../dri2xhtml.xsl"/>
<xsl:output indent="yes"/>
<xsl:template
match="*/a...@title='#aspect_artifactbrowser_Navigation_list_account
']">
<xsl:choose>
<xsl:when test="/dri:document/dri:meta/dri:userMeta/@authenticated = 'no'">
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="dri:head" />
<div>
<xsl:call-template name="standardAttributes">
<xsl:with-param name="class">ds-option-set</xsl:with-param>
</xsl:call-template>
<ul class="ds-simple-list">
<xsl:apply-templates select="dri:item" mode="nested"/>
</ul>
</div>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
</xsl:stylesheet>
#########################
And in structural.xsl, I removed the contents of the otherwise clause:
...
<xsl:choose>
<xsl:when
test="/dri:document/dri:meta/dri:userMeta/@authenticated = 'yes'">
<div id="ds-user-box">
<p>
<a>
<xsl:attribute name="href">
<xsl:value-of
select="/dri:document/dri:meta/dri:userMeta/
dri:metada...@element='identifier' and @qualifier='url']"/>
</xsl:attribute>
<i18n:text>xmlui.dri2xhtml.structural.profile</i18n:text>
<xsl:value-of
select="/dri:document/dri:meta/dri:userMeta/
dri:metada...@element='identifier'
and @qualifier='firstName']"/>
<xsl:text> </xsl:text>
<xsl:value-of
select="/dri:document/dri:meta/dri:userMeta/
dri:metada...@element='identifier'
and @qualifier='lastName']"/>
</a>
<xsl:text> |</xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of
select="/dri:document/dri:meta/dri:userMeta/
dri:metada...@element='identifier' and @qualifier='logoutURL']"/>
</xsl:attribute>
<i18n:text>xmlui.dri2xhtml.structural.logout</i18n:text>
</a>
</p>
</div>
</xsl:when>
<xsl:otherwise>
<--<div id="ds-user-box">
<p>
<a>
<xsl:attribute name="href">
<xsl:value-of
select="/dri:document/dri:meta/dri:userMeta/
dri:metada...@element='identifier' and @qualifier='loginURL']"/>
</xsl:attribute>
<i18n:text>xmlui.dri2xhtml.structural.login</i18n:text>
</a>
</p>
</div>
-->
</xsl:otherwise>
####################
Neither worked.
I am at a total loss.
Please help.
Thanks,
Marvin
------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 & L3.
Spend less time writing and rewriting code and more time creating great
experiences on the web. Be a part of the beta today
http://p.sf.net/sfu/msIE9-sfdev2dev
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech