summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-freifunk-widgets/luasrc/view/freifunk
diff options
context:
space:
mode:
authorSven Roederer <freifunk@it-solutions.geroedel.de>2019-02-03 14:13:35 +0100
committerSven Roederer <freifunk@it-solutions.geroedel.de>2019-02-13 21:23:34 +0100
commit4654ba92c3999d84b08211f05d2ccb5ea9da731b (patch)
tree06cedf8e8badc0ce584d8bd5e97fab7476c81549 /applications/luci-app-freifunk-widgets/luasrc/view/freifunk
parenteda8f02dac3caa4d0f52cd1e860d7a392c295df3 (diff)
treewide: move freifunk-related packages to separate repo
Even Freifunk was one of the major factory to create the LuCI-system, it's now only a very small part of LuCI. LuCI has become a much bigger thing and it seems that it's time to move the packages only relating to Freifunk into it's own feed. On the mailinglist it was discussed [1] and a repo below the general Freifunk team on github was created. This commit removes all packages that will be hosted in the new repo [2] 1 - http://lists.freifunk.net/pipermail/wlannews-freifunk.net/2019-February/004818.html 2 - https://github.com/freifunk/openwrt-packages Signed-off-by: Sven Roederer <freifunk@it-solutions.geroedel.de>
Diffstat (limited to 'applications/luci-app-freifunk-widgets/luasrc/view/freifunk')
-rw-r--r--applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/clear/main.htm15
-rw-r--r--applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/html/main.htm42
-rw-r--r--applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/iframe/main.htm45
-rw-r--r--applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/rssfeed/main.htm84
-rw-r--r--applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/search/main.htm54
5 files changed, 0 insertions, 240 deletions
diff --git a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/clear/main.htm b/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/clear/main.htm
deleted file mode 100644
index df01839f4..000000000
--- a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/clear/main.htm
+++ /dev/null
@@ -1,15 +0,0 @@
-<%
---[[
-LuCI - Lua Configuration Interface
-
-Copyright 2012 Manuel Munz <freifunk at somakoma dot de>
-
-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
-
-]]--
-%>
-<div style="clear:both"></div>
diff --git a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/html/main.htm b/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/html/main.htm
deleted file mode 100644
index 46e063b24..000000000
--- a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/html/main.htm
+++ /dev/null
@@ -1,42 +0,0 @@
-<%
---[[
-LuCI - Lua Configuration Interface
-
-Copyright 2012 Manuel Munz <freifunk at somakoma dot de>
-
-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
-
-]]--
-
---local utl = require "luci.util"
-local fs = require "nixio.fs"
-local title = data.title
-local name = data['.name']
-local file = "/usr/share/customtext/" .. name .. ".html"
-local text = fs.readfile(file)
-local width = data.width or "100%"
-local pr = data.paddingright or "0"
-if type(width) == "number" then
- width = width .. "px"
-end
-
-%>
-
-<div id="<%=name%>" style="width:<%=width%>;float:left">
- <div style="padding-right: <%=pr%>">
- <% if title then %>
- <h2><%=title%></h2>
- <% end %>
- <% if text then %>
- <%=text%>
- <%else%>
- <%:Could not load the custom text from%> "<%=file%>!"
- <%end%>
-
- <%=data.text%>
- </div>
-</div>
diff --git a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/iframe/main.htm b/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/iframe/main.htm
deleted file mode 100644
index f0d89d742..000000000
--- a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/iframe/main.htm
+++ /dev/null
@@ -1,45 +0,0 @@
-<%
---[[
-LuCI - Lua Configuration Interface
-
-Copyright 2012 Manuel Munz <freifunk at somakoma dot de>
-
-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
-
-]]--
-
-local url = data['url']
-local name = data['.name']
-local title = data['title'] or "No title set"
-local height = data['height'] or "400px"
-if type(height) == "number" then
- height = height .. "px"
-end
-local width = data['width'] or "100%"
-if type(width) == "number" then
- width = width .. "px"
-end
-
-%>
-
-<div id="<%=name%>" style="width:<%=width%>;float:left;">
-<h2><%=title%></h2>
-
-<% if not url then %>
-
-<%:No url set.%>
-
-<% else %>
-<div style="height:<%=height%>;min-height:<%=height%>">
-<object type="text/html" data="<%=url%>" width="100%" height="<%=height%>" name="widget_<%=name%>" id="widget_<%=name%>">
-<param name="src" value="<%=url%>" />
-<%:Sorry, your browser doesn't support the object tag and cannot display this page:%><br />
-<a href="<%=url%>"><%=url%></a>
-</object>
-</div>
-</div>
-<%end%>
diff --git a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/rssfeed/main.htm b/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/rssfeed/main.htm
deleted file mode 100644
index ff81ba8a6..000000000
--- a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/rssfeed/main.htm
+++ /dev/null
@@ -1,84 +0,0 @@
-<%
---[[
-LuCI - Lua Configuration Interface
-
-Copyright 2012 Manuel Munz <freifunk at somakoma dot de>
-
-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
-
-]]--
-
-local sys = require "luci.sys"
-local utl = require "luci.util"
-local fs = require "nixio.fs"
-local i18n = require "luci.i18n"
-local url = data.url
-local title = data.title or i18n.translate("RSS")
-local max = tonumber(data.max) or 10
-local rss
-local pr = data.paddingright or "0"
-local output = {}
-local width = data.width or "100%"
-if type(width) == "number" then
- width = width .. "px"
-end
-local name = data['.name']
-local cachetime = tonumber(data.cache) or 3600
-cachefile = "/tmp/" .. name .. ".cache"
-%>
-<div id="<%=name%>" style="width:<%=width%>;float:left">
- <div style="padding-right: <%=pr%>">
- <h2><%=title%></h2>
-
- <% if not url then %>
- <%:No url found in config%>
- <% else
- local mtime = fs.stat(cachefile, "mtime") or 0
- local now = os.time()
- expire = mtime + cachetime
-
- if not fs.access(cachefile) or expire < now then
- rss = sys.httpget(url)
- if #rss == 0 then
- %>
- <%:Could not get rss data from%> <a href="<%=url%>"><%=url%></a>
- <%
- else
- local count = 0
- for item in string.gmatch(rss, "<item>(.-)</item>") do
- if count < max then
- local title = item:match("<title>(.-)</title>")
- local link = item:match("<link>(.-)</link>")
- local desc = item:match("<description>(.-)</description>") or ""
- if title and link then
- table.insert(output, { title = utl.pcdata(title), link = utl.pcdata(link) })
- end
- count = count + 1
- end
- end
- if count > 0 then
- local file = io.open(cachefile, "w")
- file:write(utl.serialize_data(output))
- file:close()
- end
- end
- else
- local file = assert(io.open(cachefile))
- output = utl.restore_data(file:read'*a')
- end
- end
-
- if #output > 0 then
- %>
- <ul>
- <% for k, v in ipairs(output) do %>
- <li><a href="<%=v.link%>"><%=v.title%></a></li>
- <% end %>
- </ul>
- <%end%>
- </div>
-</div>
diff --git a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/search/main.htm b/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/search/main.htm
deleted file mode 100644
index f2e2fb906..000000000
--- a/applications/luci-app-freifunk-widgets/luasrc/view/freifunk/widgets/search/main.htm
+++ /dev/null
@@ -1,54 +0,0 @@
-<%
---[[
-LuCI - Lua Configuration Interface
-
-Copyright 2012 Manuel Munz <freifunk at somakoma dot de>
-
-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
-
-]]--
-local utl = require "luci.util"
-local title = luci.i18n.translate(data.title or "Search")
-local name = data['.name']
-local width = data.width or "100%"
-
-if type(width) == "number" then
- width = width .. "px"
-end
-
-local engines = {}
-if type(data.engine) == "table" then
- engines = data.engine
-else
- for k, v in ipairs(string.split(data.engine, " ")) do
- table.insert(engines, v)
- end
-end
-%>
-
-<div id="<%=name%>" style="width:<%=width%>;float:left">
- <h2><%=title%></h2>
- <div id="form_<%=name%>">
- <form name="searchform" id="search_<%=name%>" action="<%=url('freifunk/search_redirect')%>">
- <input type="text" name="searchterms" style="margin-bottom:15px; width: 90%"><br />
- <%
- local checked = " checked"
- for k, v in ipairs(engines) do
- local e = utl.split(v, "|")
- local name = e[1]
- local url = e[2]
- if name and url then
- %>
- <input name="engine" type="radio" value="<%=url%>"<%=checked%>> <%=name%><br />
- <% end
- checked = ""
- end
-%>
- <input type="submit" name="SearchSubmit" value="Search" style="margin-top: 15px">
- </form>
- </div>
-</div>