Hi Conor

Apologies this hasn't been documented.

You need to create a new directory with the same ID as the custom view id as the folder name e.g. /var/www/fez/templates/en/1

Inside there you put any templates you want to override the default one e.g. For http://digilib.library.uq.edu.au in that dir we have:

banner.tpl.html      gallery_list.tpl.html  navigation.tpl.html  view_form.tpl.html
front_page.tpl.html  list_form.tpl.html     page.tpl.html        view.tpl.html

Then in your apache or nginx config you need to add rewrites that include the custom view pid like this for nginx:

# DIGILIB CUSTOM VIEW
if ($host = 'digilib.library.uq.edu.au') {
        rewrite     ^/collection/([A-Za-z]+):([0-9]+)$                   /list.php?custom_view_pid=UQ:3682&collection_pid=$1:$2;
        rewrite     ^/collection/([A-Za-z]+):([0-9]+)/(.+)$              /list.php?custom_view_pid=UQ:3682&collection_pid=$1:$2&$3;
        rewrite     ^/community/([A-Za-z]+):([0-9]+)$                   /;
        rewrite     ^/community/([A-Za-z]+):([0-9]+)/(.+)$              /;
        rewrite     ^/view/([A-Za-z]+):([0-9]+)(\?.*)*$                  /view.php?custom_view_pid=UQ:3682&pid=$1:$2$3;
        rewrite     ^/list/([^/]*)/([^/]*)(/?)$                          /list.php?custom_view_pid=UQ:3682&browse=$1&value=$2;
        rewrite     ^/list/(.*)$                                         /list.php?custom_view_pid=UQ:3682&$1;
        rewrite     ^/favourites(/?)(.*)$                                /list.php?browse=favourites&custom_view_pid=UQ:3682&$2;
        rewrite     ^/eserv/([A-Za-z]+):([0-9]+)/(.+)(/.+)*$             /eserv.php?pid=$1:$2&dsID=$3$4 last;
        rewrite     ^/stream/([A-Za-z]+):([0-9]+)/(.+)(/.+)*$             /eserv.php?pid=$1:$2&stream=1&dsID=$3$4;
        rewrite     ^/js/(.*).js$                                            /min.php?js/$1.js;
        rewrite     ^/index.php$                                         /index.php?custom_view_pid=UQ:3682&community_pid=UQ:3682 last;
        rewrite     ^/(.*)$                                              /$1?custom_view_pid=UQ:3682  last;
}

Or like this for apache:

https://code.library.uq.edu.au/espace/file/d4aa7fdfe2f9/.htaccess

And setup your apache/nginx to add the extra hostname to your vhost config.

Cheers,
Christiaan




From: "McTernan, Conor" <mcternan@unu.edu>
Reply-To: <fez-users@lists.sourceforge.net>
Date: Wed, 7 Mar 2012 02:26:54 +0000
To: "fez-users@lists.sourceforge.net" <fez-users@lists.sourceforge.net>
Subject: [Fez-users] Custom Views

I seem to be having some trouble understanding how to implement Custom Views.

 

I have searched through the wiki, but have been unable to find any explanation as to how to use or set them up.

 

I am assuming that you need to create the custom view, defining which keys should be displayed in this view, and then assign the view to a community.

 

It’s here where I am having trouble, since I cannot seem to figure out how to actually see this view once assigned to the community.

 

Are there any resources on the wiki or in the list archives? I’ve tried searching for “custom view” in both locations but have been unable to find anything.

 

Cheers,

 

Conor

------------------------------------------------------------------------------ Virtualization & Cloud Management Using Capacity Planning Cloud computing makes use of virtualization - but cloud computing also focuses on allowing computing to be delivered as a service. http://www.accelacomm.com/jaw/sfnl/114/51521223/_______________________________________________ Fez-users mailing list Fez-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/fez-users