Dspace 4.1 JSPUI customization

1.6k views Asked by At

How can i customize DSpace 4.1 JSPUI user Interface. I have downloaded Bootstrap and Repackaged JSPUI, but still unable to make the changes effect.

1

There are 1 answers

0
pnbecker On

Mostly it this results from browser caches. So clean your browser cache and check if this helps.

The JSPUI layout depends on the JSPs and the css and javascript files referred in the JSPs. You find the original files in the directory [dspace-source]/dspace-jspui/src/main/webapp/layout. Before editing you should copy them to [dspace-source]/dspace/modules/jspui/src/main/webapp/layout (create the directories if they do not exist already). Copying the files will help you if you want to upgrade to a newer DSpace version one day. This overlay mechanism is described in the DSpace documentation (https://wiki.duraspace.org/display/DSDOC4x/JSPUI+Configuration+and+Customization).

After changing the files you have to use maven and ant to compile DSpace and copy all the files into the installation directory of DSpace. Use 'mvn package' to compile, change into the directory [dspace-source]/dspace/target/dspace-[version].dir and call "ant update" to copy the files to their destinations. Restart tomcat after updating DSpace.

You can copy JSPs, css, images and javascript files manually to [dspace-install] directory. But using ant the next time will overwrite files withing this directory, so make sure you keep the files in [dspace-source] directory up to date.

In some strange cases it may happen that tomcat delivers new images, css and javascript files but still has old JSPs in its cache. In this case it helps to "touch" the JPS. Under Unix/Linux you can do this by using find and touch, g.e. "find [dspace-install] -name '*.jsp' -exec touch {} \;".

If this did not helped, check the following: 1.) Do you see the new files under [dspace-install]/webapps/jspui/? Do they contain the new/changed content? If not there was a problem compiling or using ant. 2.) Does the tomcat delivers new images, javascript or css files? To check this just call the URI of such a file directly. 3.) Does the generate HTML looks like you expect it? 4.) Are there errors or warnings in the developer console of your browser?

Hope this helps.