Just Launched: You can now import projects and releases from Google Code onto SourceForge
We are excited to release new functionality to enable a 1-click import from Google Code onto the Allura platform on SourceForge. You can import tickets, wikis, source, releases, and more with a few simple steps. Read More
From: George Oliver <georgeolivergo@ya...> - 2008-07-16 01:47:41
Just wanted to post up my answer to this earlier question, as I hadn't found a short and clear answer in the archives when I checked. Of course the answer is a fairly easy one :).
In balanced.py there are two functions, header() and footer(), each returning a list called html (among other items). The list html is composed of a number of functions which display things like the search form, editing links, and so forth, and to add a new link you just need to choose which function you want to add to.
I chose the function username(); that function returns a list called userlinks, and to add a link all you do is
userlinks.append(u'<a href="<your link goes here>">Your link name</a>')
Do this just before the list comprehension at the end of the username() defintion (or wherever is appropriate if you choose a different function).
Your link probably will be relative, like "/<relative link".
As to the problem of refreshing, I'm not totally clear on the issues but what I needed to do was delete the compiled balanced.pyc and restart the Apache server after a change. This seems to clear up the problem, by I'm guessing generating a new .pyc from the edited balanced.py.