diff options
author | Choom | 2023-01-15 03:12:48 -0300 |
---|---|---|
committer | Choom | 2023-01-16 14:37:04 -0300 |
commit | 4c31093827f57394563de037a21143407586e384 (patch) | |
tree | b16abeb0dc76e48e11f8c0264fa39ce6294458d2 /cgi/templates | |
parent | 44f7397cf7a7596edea78864122b78d59983701e (diff) | |
download | weabot-4c31093827f57394563de037a21143407586e384.tar.gz weabot-4c31093827f57394563de037a21143407586e384.tar.xz weabot-4c31093827f57394563de037a21143407586e384.zip |
Autorefresh en home
Diffstat (limited to 'cgi/templates')
-rw-r--r-- | cgi/templates/feed.rss | 25 | ||||
-rw-r--r-- | cgi/templates/home.html | 34 | ||||
-rw-r--r-- | cgi/templates/home.rss | 25 | ||||
-rw-r--r-- | cgi/templates/mobile/latest.html | 4 | ||||
-rw-r--r-- | cgi/templates/mobile/newest.html | 4 |
5 files changed, 48 insertions, 44 deletions
diff --git a/cgi/templates/feed.rss b/cgi/templates/feed.rss new file mode 100644 index 0000000..dfce578 --- /dev/null +++ b/cgi/templates/feed.rss @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8" ?>
+<rss version="2.0">
+ <channel>
+ <title>Bienvenido a Internet BBS/IB</title>
+ <link>https://bienvenidoainternet.org/</link>
+ <description>El BBS/IB más activo de la esfera hispana.</description>
+ <language>es</language>
+ <webMaster>burocracia@bienvenidoainternet.org (Staff ★)</webMaster>
+ <image>
+ <url>https://bienvenidoainternet.org/rss_logo.png</url>
+ <title>Bienvenido a Internet BBS/IB</title>
+ <link>https://bienvenidoainternet.org/</link>
+ <width>144</width>
+ <height>144</height>
+ </image>
+ <?py for post in posts: ?>
+ <item>
+ <title>${post['board_name']}: #{post['content']}</title>
+ <pubDate>${post['timestamp_formatted']}</pubDate>
+ <link>https://bienvenidoainternet.org#{post['url']}</link>
+ <description>${post['content']}</description>
+ </item>
+ <?py #endfor ?>
+ </channel>
+</rss>
diff --git a/cgi/templates/home.html b/cgi/templates/home.html index d60b719..b5d932b 100644 --- a/cgi/templates/home.html +++ b/cgi/templates/home.html @@ -73,25 +73,29 @@ </tr> <tr> <td rowspan="2" class="tab"> - <h2 id="newposts">Hilos activos <div id="counter"></div></h2> - <h4>BBS</h4> - <div id="postlist" class="threads"> + <h2 id="newposts">Hilos activos <a href="bai.rss" target="_blank"><img src="/feed.png" style="width:12px;height:12px;"></a></h2> + <h4>BBS</h4> + <div id="postlistbbs" class="threads"> <?py for thread in latest_age_bbs: ?> - <a href="${thread['url']}" class="thread"><span class="brd">[${thread['board_name']}:${'%03d' % thread['length']}]</span> #{thread['content']}</a> + <a href="${thread['url']}" class="thread"><span class="brd">[${thread['board_abr']}:${'%03d' % thread['length']}]</span> #{thread['content']}</a> <?py #endfor ?> - </div> - <hr /> - <h4>IB</h4> - <div id="postlist" class="threads"> + </div> + <hr /> + <h4>IB</h4> + <div id="postlistib" class="threads"> <?py for thread in latest_age_ib: ?> - <a href="${thread['url']}" class="thread"><span class="brd">[${thread['board_name']}:${'%03d' % thread['length']}]</span> #{thread['content']}</a> + <a href="${thread['url']}" class="thread"><span class="brd">[${thread['board_abr']}:${'%03d' % thread['length']}]</span> #{thread['content']}</a> <?py #endfor ?> + </div> + <hr /> + <div id="ctrl"><a id="refresh" href="/home.html">Actualizar</a> + <span> + <input id="autorefresh" type="checkbox" /><label for="autorefresh">Automático</label> + <span id="counter"></span> + </span> + <span><input id="autosound" type="checkbox" checked="checked" disabled="disabled" /><label for="autosound">Sonido</label><audio id="machina"><source src="msn.ogg" type="audio/ogg" /></audio></span> + <input type="hidden" name="limit" id="limit" value="#{latest_age_num}" /> </div> - <hr /> - <div id="ctrl"><a id="refresh" href="/home.html">Actualizar</a> - <span><input id="autorefresh" type="checkbox" /><label for="autorefresh">Automático</label><audio id="machina"><source src="msn.ogg" type="audio/ogg" /></audio></span> - <span><input id="autosound" type="checkbox" checked="checked" disabled="disabled" /><label for="autosound">Sonido</label><input type="hidden" name="limit" id="limit" value="#{latest_age_num}" /></span> - <a href="bai.rss"><img src="/rss.png" style="width:12px;height:12px;margin-right:4px;">RSS</a></div> </td> <td id="newstab" class="tab"> <h2>Blotter</h2> @@ -107,7 +111,7 @@ <h2>Hilos nuevos</h2> <div id="new_ib" class="threads"> <?py for thread in new_threads: ?> - <a href="${thread['url']}" class="thread"><span class="brd">[${thread['board_name']}]</span> #{thread['content']}</a> + <a href="${thread['url']}" class="thread"><span class="brd">[${thread['board_abr']}]</span> #{thread['content']}</a> <?py #endfor ?> </div> </td> diff --git a/cgi/templates/home.rss b/cgi/templates/home.rss deleted file mode 100644 index 1e5f552..0000000 --- a/cgi/templates/home.rss +++ /dev/null @@ -1,25 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" ?>
-<rss version="2.0">
- <channel>
- <title>Bienvenido a Internet BBS/IB</title>
- <link>https://bienvenidoainternet.org/</link>
- <description>El BBS/IB más activo de la esfera hispana.</description>
- <language>es</language>
- <webMaster>burocracia@bienvenidoainternet.org (Staff ★)</webMaster>
- <image>
- <url>https://bienvenidoainternet.org/rss_logo.png</url>
- <title>Bienvenido a Internet BBS/IB</title>
- <link>https://bienvenidoainternet.org/</link>
- <width>144</width>
- <height>144</height>
- </image>
-<?py for post in posts: ?>
- <item>
- <title>${post['board_fulln']}: #{post['content']}</title>
- <pubDate>${post['timestamp_formatted']}</pubDate>
- <link>https://bienvenidoainternet.org#{post['url']}</link>
- <description>${post['message']}</description>
- </item>
-<?py #endfor ?>
- </channel>
-</rss>
diff --git a/cgi/templates/mobile/latest.html b/cgi/templates/mobile/latest.html index 50fae25..8156e69 100644 --- a/cgi/templates/mobile/latest.html +++ b/cgi/templates/mobile/latest.html @@ -8,13 +8,13 @@ <div class="list"> <h3 style="text-align:center">BBS</h3> <?py for thread in latest_age_bbs: ?> - <a href="/cgi/mobileread${thread['url']}">#{thread['content']}<div>${thread['board_fulln']} <span>R:<span>#{int(thread['length'])-1}</span></span></div></a> + <a href="/cgi/mobileread${thread['url']}">#{thread['content']}<div>${thread['board_name']} <span>R:<span>#{int(thread['length'])-1}</span></span></div></a> <?py #endfor ?> </div> <div class="list"> <h3 style="text-align:center">IB</h3> <?py for thread in latest_age_ib: ?> - <a href="/cgi/mobileread${thread['url']}">#{thread['content']}<div>${thread['board_fulln']} <span>R:<span>#{int(thread['length'])-1}</span></span></div></a> + <a href="/cgi/mobileread${thread['url']}">#{thread['content']}<div>${thread['board_name']} <span>R:<span>#{int(thread['length'])-1}</span></span></div></a> <?py #endfor ?> </div> </body> diff --git a/cgi/templates/mobile/newest.html b/cgi/templates/mobile/newest.html index 37fd67f..76da88b 100644 --- a/cgi/templates/mobile/newest.html +++ b/cgi/templates/mobile/newest.html @@ -7,8 +7,8 @@ <div class="bar"><a href="//m.bienvenidoainternet.org">Secciones</a><a href="/cgi/mobilehome">Hilos activos</a><a href="/cgi/mobilenewest" class="sel">Nuevos hilos</a></div> <div class="list"> <?py for thread in newthreads: ?> - <a href="/cgi/mobileread${thread['url']}">#{thread['content']}<div>${thread['board_fulln']}</div></a> + <a href="/cgi/mobileread${thread['url']}">#{thread['content']}<div>${thread['board_name']}</div></a> <?py #endfor ?> </div> </body> -</html>
\ No newline at end of file +</html> |