Sharing gnucash.css between htdocs and mail-search?

Neil Williams linux at codehelp.co.uk
Tue Jan 17 16:09:15 EST 2006


On Tuesday 17 January 2006 8:21 pm, Derek Atkins wrote:
> I was wondering what you think about sharing gnucash.css between
> the htdocs (website) and the mail-search modules?  Do you think
> it's reasonable to work towards sharing the same css and support
> (iconsm etc)?

Yes, but I thought about the two servers and wondered how it would be done.

It is, essentially, the same file but it's actually quite small and I think 
the bigger benefit comes from sharing the menu*.phtml files. 

Sharing the menu files would mean that the search page links are always in 
step with all the other pages. It seems strange for one page to have the 
wrong links like that. search.php can include the menu files directly but 
that's extra network traffic each time the search page is displayed. Better 
if - once I'm done - future changes to the en/menu/* files get propagated to 
mail-search.

Problem: We'd have to have absolute URL's in the menu links which makes it 
hard to test the htdocs/ svn locally - or use a PHP redirect but that would 
be executed each time, not just when testing. That could be a real PITA. 
Alternatively, scripting the links means either generating them every time a 
page is viewed according to the current host (bad) or creating a bespoke 
commit hook that tries to mangle the local links to absolute (sounds like 
trouble).

Once I'm done here, the CSS isn't likely to change that much - and there will 
be new parts to gnucash.css that aren't needed in search.css. It's as easy to 
copy the CSS file across locally between the two trees and make a separate 
commit, if there are changes that need to be shared. I'll make sure there 
aren't any overlaps so if it's better to have just one CSS with some 
redundant content, we can do that too.

> One approach to sharing would be moving gnucash.css from the top-level
> and into its own subdirectory (htdocs/css/gnucash.css) and then
> in the mail-search we could use the subversion svn:externals

<snip>

> It would imply that changes to the css get propagated into both
> locations, which would make it much easier to keep it all in sync.
>
> What do you think?

Whichever way we do it, sharing one site across two servers is going to make 
things difficult. We can't move mail-search without moving the list archives. 
If we want mail-search truly joined up with the rest of the content the only 
real solution is to move the gnucash.org website to lists.gnucash.org.

We may just have to live with copying files between sites and adapting where 
necessary.

-- 

Neil Williams
=============
http://www.data-freedom.org/
http://www.nosoftwarepatents.com/
http://www.linux.codehelp.co.uk/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.gnucash.org/pipermail/gnucash-devel/attachments/20060117/42fbcbfb/attachment.bin


More information about the gnucash-devel mailing list