Hello Everybody

 

Dspace 3.1/xmlui version

 

We borrowed  jquery code from somewhere where they implemented on the following site

http://repository.cimmyt.org/

 

The instruction they gave us  quite simple. However it doesn’t work for us i.e. the links

on page can’t be collapsible.

Is there someone who has some hints on this

The instruction looks as follow

 

Fi l e

{dspace-­‐src}\dspace-­‐xmlui\dspace-­‐xmlui-­‐webapp\src\main\webapp\themes\Mirage\lib\xsl\core\page-­‐structure

 

Add in template ‘<xsl:template name="buildHead">’the following jquery code

 

 

<script type="text/javascript">

<xsl:attribute name="src">

<xsl:text>http://code.jquery.com/jquery-1.9.1.js</xsl:text>

</xsl:attribute>&#160;</script>

<script type="text/javascript">

<xsl:attribute name="src">

<xsl:text>http://code.jquery.com/ui/1.10.3/jquery-ui.js</xsl:text>

</xsl:attribute>&#160;</script>

<script type="text/javascript">

$(function(){

$('#aspect_discovery_Navigation_list_discovery ul li

h2').click(function(event){

var elem = $(this).next();

if(elem.is('ul')){

event.preventDefault();

$('#menu ul:visible').not(elem).slideUp();

elem.slideToggle();

}

});

});

</script>

 

 

 

 

Add new file with the following code

{dspace-­‐src}\dspace-­‐xmlui\dspace-­‐xmlui-­‐

webapp\src\main\webapp\themes\Mirage\lib\css\discovery.css

 

 

#aspect_discovery_Navigation_list_discovery ul li ul{

display: none;

}

#aspect_discovery_Navigation_list_discovery ul li h2{

cursor:pointer; cursor: hand;

 

 

F i l e

{dspace-­‐src}\dspace-­‐xmlui\dspace-­‐xmlui-­‐webapp\src\main\webapp\themes\Mirage\sitemap.xmap

 

Add link to discovery.css

 

<map:transform type="IncludePageMeta">

<map:parameter name="stylesheet.screen#1" value="lib/css/reset.css"/>

<map:parameter name="stylesheet.screen#2" value="lib/css/base.css"/>

<map:parameter name="stylesheet.screen#3" value="lib/css/helper.css"/>

<map:parameter name="stylesheet.screen#4" value="lib/css/jquery-ui-

1.8.15.custom.css"/>

<map:parameter name="stylesheet.screen#5" value="lib/css/style.css"/>

<map:parameter name="stylesheet.screen#6" value="lib/css/authoritycontrol.

css"/>

<map:parameter name="stylesheet.screen#7" value="lib/css/discovery.css"/>

</map:transform>