Hello Brian,

On Mon, Jul 29, 2013 at 1:29 PM, Brian Aljer B. Coballes <
[email protected]> wrote:

> Hi Elvi, sorry to disturb you. I'm implementing the expand/collapse button
> in communities/collection. I'e seen you're post in dspace nabble. I'm
> trying to patch the code (err manually) so that I'm sure where the changes
> will go. But apparently, I cannot have it work. All the js and css are in
> their respective folders in Mirage template. Any advise? Thanks.
>

To display the full list of your communities and collections in the front
page, edit line 48:

"<map:parameter name="depth" value="1"/>"

 change the value from 1 to 999 in
[dspace-src]\dspace-xmlui\src\main\resources\aspects\BrowseArtifacts\sitemap.xmap.

If you are using mirage, copy this line and paste it in the mirage.xsl file
before the closing tag "</xsl:stylesheet>:

    <xsl:template match="dri:referenceSet[@type = 'summaryList' and
@n='community-browser']" priority="3">
        <div id="sidetree">
            <div class="treeheader">&#160;</div>
            <div id="sidetreecontrol"><a href="?#">Collapse All</a>&#160;
                <a href="?#">Expand All</a>
            </div>
            <ul id="tree">
                <xsl:apply-templates select="*[not(name()='head')]"
mode="summaryList"/>
            </ul>
        </div>
    </xsl:template>

Also, you must edit
[dspace-src]\dspace-xmlui\src\main\webapp\themes\Mirage\sitemap.xmap to
make sure all the necessary css and javascripts were imported. E.g.:

                <map:transform type="IncludePageMeta">
                    *<map:parameter name="stylesheet#1"
value="lib/treeview/jquery.treeview.css"/>*
                    <map:parameter name="javascript#1"
value="lib/js/jquery-ui-1.8.15.custom.min.js"/>
                    <map:parameter name="javascript#2"
value="lib/jquery/jquery.cookie.js"/>
                    *<map:parameter name="javascript#3"
value="lib/treeview/jquery.treeview.js"/>*
                    *<map:parameter name="javascript#4"
value="lib/treeview/treeview.js"/>*
                    <map:parameter name="stylesheet.all"
value="lib/css/media.css"/>
                    <map:parameter name="theme.path"
value="{global:theme-path}"/>
                    <map:parameter name="theme.name"
value="{global:theme-name}"/>
                </map:transform>

Note that the number sequence (e.g. javascript#3, etc.) are crucial, I
always made the mistake of not updating these numbers which in turn failed
to import or link these files.

Rebuild DSpace.

If you're using chrome, always try to use the 'inspect element' feature and
view the console, this well help you monitor and fix any errors that you
might encounter. You can also add firebug if you are using firefox and view
the console tab for any errors. Look for javascript errors (e.g. 'treeview
is not a function') in the console, these could be one of the reasons that
you can't get to work. I'm not a javascript expert but based from my
experience, these errors were caused by jQuery conflicts (see my post about
these, answered by helix:
http://www.mail-archive.com/[email protected]/msg22855.html
).

As suggested by dspace experts, it is highly recommended to create a new
theme if you want to try theme customizations to avoid overwriting your
customizations the next time you update/build your dspace. Please see this
link: https://wiki.duraspace.org/pages/viewpage.action?pageId=19006130.

Please cc dspace-tech in asking questions about technical details in
dspace, I might not answer your query satisfactorily and someone from the
list could advise or have a better solution. I can also be wrong and
someone can correct that or point it out, an added advantage to all of us
dspace users. ;-) And this will also help other users who may encounter the
same problems.

Cheers and Regards,

--
Elvi S. Nemiz
Information Assistant
Library and Data Bank Services Section
Training and Information Division
SEAFDEC Aquaculture Department
Tigbauan, Iloilo
Philippines
------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent 
caught up. So what steps can you take to put your SQL databases under 
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette

Reply via email to