EPrints Technical Mailing List Archive

Message: #07244


< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First

Re: [EP-tech] https://researchdata.bath.ac.uk/ site template


Hi Yuri,

Branded templates for particular institutions will not freely available
by default.  This is because of potential copyright issues with re-
using another institutions branding, even if you exclude logos, etc.
 Also, if you do use them, you have to be careful not to accidentally
include things like Google Analytics User Agent (UA) IDs, etc.

There is a way of taking the look and feel of a page and using it as an
EPrints template.  However, if this is not your page, (e.g. you do not
just want your repository to look like you institution's main website),
you should really ask the owner of the site's permission.

Here are some basic instructions how to use an existing branded page:

wget http://www.example.org/ -O
archives/ARCHIVENAME/cfg/lang/en/templates/default.html

cd archives/ARCHIVENAME/cfg/lang/en/templates/

dos2unix default.html

xmllint --xmlout --format default.html > default.xml

(I think --xmlout

Replace &nbsp; with &#160; and &copy; with &#169; until you get a page
that is valid XML.  This may require other changes but you will need to
read the error messages and work out what to do based on them.

Download all the associated CSS, Javascript, etc.  The best way is to
get a list of these by using the developer toolbar's network tab and
doing a Ctrl+Shift+R on the web page.  You will then need to download
these files to the appropriate places under the archive's cfg/static/
and then update the links in default.xml to point at the local copies
in their correct locations. (e.g. style/example.css
javascript/example.js, images/logo.png, etc.)

Add the following line to the <head> section of default.xml

<meta http-equiv="X-UA-Compatible" content="IE=edge" />

Remove lines in the HTML like Google site verification and user agent
IDs, etc.

You then want to add the EPrints pins (e.g. <epc:pin ref="page"/>).
 Check out what pins you need in EPrints default template
in lib/templates/default.xml

Create spaces for you own CSS and Javascript modification by creating
the files:

archives/ARCHIVENAME/cfg/static/style/auto/zzz_local.css

and

archives/ARCHIVENAME/cfg/static/javascript/auto/zzz_local.js

These should be used to tie in the EPrints CSS and Javascript with that
of your branding.  If you fundamentally want to change the branding
just change the files you downloaded to archives/ARCHIVENAME/cfg/style/
, archives/ARCHIVENAME/cfg/static/javascript/ and
 archives/ARCHIVENAME/cfg/static/images/.

I am sure there are a few instructions I am missing but you should
hopefully be able to work out what you need to do.  If you get stuck, I
am sure I or someone else on the list will be able to help.

Regards

David Newman 
 




On Thu, 2018-03-22 at 11:31 +0100, Yuri wrote:
> Hi!
> 
>   is this eprints template of https://researchdata.bath.ac.uk/
> available?
> 
> About bootstrap, Is is possible to install this: 
> https://github.com/eprintsug/bootstrap/blob/master/bootstrap.epmi
> with 
> epm install? Then, how to enable it?
> 
> 
> *** Options: http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-
> tech
> *** Archive: http://www.eprints.org/tech.php/
> *** EPrints community wiki: http://wiki.eprints.org/
> *** EPrints developers Forum: http://forum.eprints.org/