summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-splash/root/usr/lib
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2008-05-25 17:00:30 +0000
committerSteven Barth <steven@midlink.org>2008-05-25 17:00:30 +0000
commit365d80765d3f08c457b0a373c395c8e1940e44be (patch)
tree480def5c83ea3df918179e26019cc93e585eda78 /applications/luci-splash/root/usr/lib
parentc6c50b3ec60b284107f459e5923c146d515afd2a (diff)
Renamed FFLuCI to LuCI, ffluci to luci and Freifunk Lua Configuration Interface to Lua Configuration Interface
Diffstat (limited to 'applications/luci-splash/root/usr/lib')
-rw-r--r--applications/luci-splash/root/usr/lib/luci-splash/htdocs/cgi-bin/index.cgi26
-rw-r--r--applications/luci-splash/root/usr/lib/luci-splash/htdocs/index.html2
2 files changed, 14 insertions, 14 deletions
diff --git a/applications/luci-splash/root/usr/lib/luci-splash/htdocs/cgi-bin/index.cgi b/applications/luci-splash/root/usr/lib/luci-splash/htdocs/cgi-bin/index.cgi
index 11430f0ac..545233d8d 100644
--- a/applications/luci-splash/root/usr/lib/luci-splash/htdocs/cgi-bin/index.cgi
+++ b/applications/luci-splash/root/usr/lib/luci-splash/htdocs/cgi-bin/index.cgi
@@ -2,17 +2,17 @@
package.path = "/usr/lib/lua/?.lua;/usr/lib/lua/?/init.lua;" .. package.path
package.cpath = "/usr/lib/lua/?.so;" .. package.cpath
-require("ffluci.http")
-require("ffluci.sys")
-require("ffluci.model.uci")
+require("luci.http")
+require("luci.sys")
+require("luci.model.uci")
local srv
local net
-local ip = ffluci.http.env.REMOTE_ADDR
-for k, v in pairs(ffluci.model.uci.sections("network")) do
+local ip = luci.http.env.REMOTE_ADDR
+for k, v in pairs(luci.model.uci.sections("network")) do
if v[".type"] == "interface" and v.ipaddr then
- local p = ffluci.sys.net.mask4prefix(v.netmask)
- if ffluci.sys.net.belongs(ip, v.ipaddr, p) then
+ local p = luci.sys.net.mask4prefix(v.netmask)
+ if luci.sys.net.belongs(ip, v.ipaddr, p) then
net = k
srv = v.ipaddr
break
@@ -21,30 +21,30 @@ for k, v in pairs(ffluci.model.uci.sections("network")) do
end
local stat = false
-for k, v in pairs(ffluci.model.uci.sections("luci_splash")) do
+for k, v in pairs(luci.model.uci.sections("luci_splash")) do
if v[".type"] == "iface" and v.network == net then
stat = true
end
end
if not srv then
- ffluci.http.prepare_content("text/plain")
+ luci.http.prepare_content("text/plain")
print("Unable to detect network settings!")
elseif not stat then
- ffluci.http.redirect("http://" .. srv)
+ luci.http.redirect("http://" .. srv)
else
local action = "splash"
- local mac = ffluci.sys.net.ip4mac(ip)
+ local mac = luci.sys.net.ip4mac(ip)
if not mac then
action = "unknown"
end
- local status = ffluci.sys.execl("luci-splash status "..mac)[1]
+ local status = luci.sys.execl("luci-splash status "..mac)[1]
if status == "whitelisted" or status == "lease" then
action = "allowed"
end
- ffluci.http.redirect("http://" .. srv .. "/cgi-bin/luci-splash/" .. action)
+ luci.http.redirect("http://" .. srv .. "/cgi-bin/luci-splash/" .. action)
end \ No newline at end of file
diff --git a/applications/luci-splash/root/usr/lib/luci-splash/htdocs/index.html b/applications/luci-splash/root/usr/lib/luci-splash/htdocs/index.html
index 58387a5fe..39ba558df 100644
--- a/applications/luci-splash/root/usr/lib/luci-splash/htdocs/index.html
+++ b/applications/luci-splash/root/usr/lib/luci-splash/htdocs/index.html
@@ -5,6 +5,6 @@
<meta http-equiv="refresh" content="0; URL=/cgi-bin/index.cgi" />
</head>
<body style="background-color: black">
-<a style="color: white; text-decoration: none" href="/cgi-bin/index.cgi">FFLuCI - Freifunk Lua Configuration Interface</a>
+<a style="color: white; text-decoration: none" href="/cgi-bin/index.cgi">LuCI - Lua Configuration Interface</a>
</body>
</html> \ No newline at end of file