I am looking for a way to get the homepage of a site so I can retrieve some values from it.
At http://doc.silverstripe.org/doku.php?id=recipes:final_parent is a function to find the final parent of a page - I got this to work and was able to get values from it to appear in my pages. It does not get me to the homepage, but I think it is a good start.
At http://doc.silverstripe.org/doku.php?id=recipes:what_to_return_from_a_function there is another recipe to get the results from a function from a specific page but ideally I would like to be able to do this without targeting a page called 'home' because I am working on a multi-language website.
What do I want to do: i want to get certain values from the homepage in each language to appear in the footer on every page in that language. (I would be using a special homepage template that has some extra fields for contact info, a short statement etc). I do not believe widgets are the answer to my problem because you have to apply them to every page manually and even if you can apply them to all the pages in the site, you need to fill in the data manually on every page. But please correct me if I am wrong - I am new here.
TIA!