On Wed, 17 Aug 2011, Diwaker Ghimire wrote:
> [I don't know how to post it to trac, Can't we assign id to these
> forms and use document.getElementById instead?]

Have you registered an account on <http://invenio-software.org/>?  There
does not seem to be any associated with your email address.  Maybe you
have used different email address?  In any case, please register an
account and please let us know your nickname so that we can grant you
the posting rights.

> my problem is related to this. I have upgraded 0.9x to 1.0rc0 recently
> the same problem existed before when using 0.9x but then i changed all
> the files to "document.forms[1]" instead as i haved messed up the core
> files of invenio as well Now i don't want to do that [messing around
> core files] so i want to remove the "header form" from other than
> websearch pages.

Ludmila answered this one already: the page() function has a `navmenuid'
argument that may be used to generate different page headers for
different modules.

> I need to have more than one virtual collections [can i do that ?].

Yes, it should work out of the box.  For example, on the Invenio demo
site, there are two right-hand-side collections entitled `CERN
Divisions' and `CERN Experiments' that are both virtual daughters of the
Home collection; so they start two distinct virtual trees etc.

> Currently what i am doing is i am adding multiple childs of root
> virtual collections and showing each of them into their own
> "narrowbox".

The virtual trees are by default shown in the `Focus on' box on the rhs.
Do I understand you right that you want to have more `Focus on' boxes,
each with different heading?

> For that i have added quite few code on websearch_webcoll.py file. My
> question is : how can i separate my code from core websearch_webcoll
> module [i need to overwrite some methods too.] so that core files
> remains clean.

Yes, it will be very good to contribute your changes back to Invenio
core, precisely in order to have clean setup that will also simplify
future site upgrades.

Depending on the concrete changes you have made, there are several
possibilities: (1) perhaps most of your changes can be maintained
locally via custom skin templates, i.e. websearch_templates_MYSITE.py.
However, if you need to touch the behaviour of Invenio core
functionality, then (2) bug fixes or universally useful feature
improvements should be submitted to Invenio as is; (3) feature
improvements that may not be universally useful should be wrapped via
configuration variables, so that every Invenio site can set the defaults
as they see fit.  For example, in order to change how the feature Foo of
the search engine behaves, a new configuration variable called
CFG_WEBSEARCH_FOO should be introduced, so that both the old behaviour
and the new behaviour can be achieved depending on how this
configuration variable is set up in every site's `invenio-local.conf'.
IOW, the new functionality will be conditional and every Invenio site
will be free to choose one way or the other way, as they see fit.

Is your site and your code publicly accessible somewhere?  It would be
helpful to see your concrete changes in order to discuss further.

Best regards
-- 
Tibor Simko

Reply via email to