Dont know if it works as I haven't needed to try it, but it is recommended by someone I trust.
Take 30 grms each of dried rosemary and sage. Add about 1/2 litre of boiling water and simmer for 5 mins. Let it cool. Everytime you wash your hair, rinse it in this solution.
Might not do any good, but I dont see how it can do any harm.