diff options
author | Manuel Munz <freifunk@somakoma.de> | 2010-11-18 03:29:17 +0000 |
---|---|---|
committer | Manuel Munz <freifunk@somakoma.de> | 2010-11-18 03:29:17 +0000 |
commit | e8a9cad684d875a2f2c6dcb94149409049d42492 (patch) | |
tree | a34826ac81d8cab5d8e123a111793c8b2220aa4b /modules/freifunk/luasrc/view | |
parent | 543e129ab56f1c96962a0c9a3d8fe2279f5cd2db (diff) |
modules/freifunk: Make the public index page editable
Diffstat (limited to 'modules/freifunk/luasrc/view')
-rw-r--r-- | modules/freifunk/luasrc/view/freifunk/index.htm | 50 |
1 files changed, 42 insertions, 8 deletions
diff --git a/modules/freifunk/luasrc/view/freifunk/index.htm b/modules/freifunk/luasrc/view/freifunk/index.htm index 736cf29da8..d93dcd8f45 100644 --- a/modules/freifunk/luasrc/view/freifunk/index.htm +++ b/modules/freifunk/luasrc/view/freifunk/index.htm @@ -13,12 +13,46 @@ $Id$ -%> <%+header%> -<% local ff = luci.model.uci.cursor():get_all("freifunk") %> -<h2><a id="content" name="content"><%:Hello and welcome in the network of%> <%=ff.community.name or 'Freifunk Deutschland'%>!</a></h2> -<p><%:We are an initiative to establish a free, independent and open wireless mesh network.%><br /> -<%:This is the access point%> <%=luci.sys.hostname()%>. <%:It is operated by%> -<a href="<%=luci.dispatcher.build_url("freifunk", "index", "contact")%>"> <%=ff.contact.nickname%></a>.</p> -<p><%:You can find further information about the global Freifunk initiative at%> <a href="http://freifunk.net">Freifunk.net</a>.<br /> -<%:If you are interested in our project then contact the local community%> <a href="<%=ff.community.homepage or 'http//freifunk.net'%>"><%=ff.community.name or 'Freifunk'%></a>.</p> -<p><strong><%:Notice%></strong>: <%:Internet access depends on technical and organisational conditions and may or may not work for you.%></p> +<% +local ff = luci.model.uci.cursor():get_all("freifunk") +require("luci.fs") +local usertext = luci.fs.readfile("/www/luci-static/index_user.html") + +if (ff.community.DefaultText or "") ~= "disabled" then + + defaulttext = '<h2><a id="content" name="content">'.. + (translate("Hello and welcome in the network of")).. + ' '.. + (ff.community.name or "Freifunk Deutschland").. + '!</a></h2><p>'.. + translate("We are an initiative to establish a free, independent and open wireless mesh network.").. + '<br />'.. + translate("This is the access point").. + ' '.. + luci.sys.hostname().. + '. '.. + translate("It is operated by").. + '<a href="'.. + luci.dispatcher.build_url("freifunk", "index", "contact").. + '"> '.. + (ff.contact.nickname or "Anonymous").. + '</a>.</p><p>'.. + translate("You can find further information about the global Freifunk initiative at").. + ' <a href="http://freifunk.net">Freifunk.net</a>.<br />'.. + translate("If you are interested in our project then contact the local community").. + ' <a href="'.. + (ff.community.homepage or "http//freifunk.net").. + '">'.. + (ff.community.name or "Freifunk").. + '</a>.</p><p><strong>'.. + translate("Notice").. + '</strong>: '.. + translate("Internet access depends on technical and organisational conditions and may or may not work for you.").. + '</p>' +end +%> + +<%=defaulttext%> +<%=usertext%> + <%+footer%> |