Fix URL to Freifunk contact page (closes #3)
[project/luci.git] / modules / freifunk / luasrc / view / freifunk / index.htm
index 7fa2b4e..0b4d697 100644 (file)
@@ -1,10 +1,24 @@
+<%#
+LuCI - Lua Configuration Interface
+Copyright 2008 Steven Barth <steven@midlink.org>
+Copyright 2008 Jo-Philipp Wich <xm@leipzig.freifunk.net>
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+$Id$
+
+-%>
 <%+header%>
-<% local ff = luci.model.uci.get_all("freifunk") %>
-<h1><%:hellonet%> <%=ff.community.name%>!</h1>
-<p><%:public1%><br />
-<%:public2%><%=luci.sys.hostname()%>. <%:public3%>
-<a href="<%=controller%>/public/index/contact"><%=ff.contact.nickname%></a>.</p>
-<p><%:public4%> <a href="http://freifunk.net">Freifunk.net</a>.<br />
-<%:public5%> <a href="<%=ff.community.homepage%>"><%=ff.community.name%></a>.</p>
-<p><strong><%:note%></strong>: <%:public6%></p>
-<%+footer%>
\ No newline at end of file
+<% local ff = luci.model.uci.cursor():get_all("freifunk") %>
+<h2><a id="content" name="content"><%:ff_hellonet%> <%=ff.community.name or 'Freifunk Deutschland'%>!</a></h2>
+<p><%:ff_public1%><br />
+<%:ff_public2%> <%=luci.sys.hostname()%>. <%:ff_public3%>
+<a href="<%=luci.dispatcher.build_url("freifunk", "index", "contact")%>"> <%=ff.contact.nickname%></a>.</p>
+<p><%:ff_public4%> <a href="http://freifunk.net">Freifunk.net</a>.<br />
+<%:ff_public5%> <a href="<%=ff.community.homepage or 'http//freifunk.net'%>"><%=ff.community.name or 'Freifunk'%></a>.</p>
+<p><strong><%:ff_note%></strong>: <%:ff_public6%></p>
+<%+footer%>