summaryrefslogtreecommitdiff
path: root/schedule.ecpp
diff options
context:
space:
mode:
authorThomas Keil <tkeil (at) datacrystal (dot) de>2007-01-02 19:37:57 +0000
committerThomas Keil <tkeil (at) datacrystal (dot) de>2007-01-02 19:37:57 +0000
commit6e6955d282944c5f2e73ab454cfcc374414986c6 (patch)
treea5cdc40d12f1d94d5be93cbf5b46574f66f11552 /schedule.ecpp
parent48c46dfdd986ad4a7a0692d05992f7882bef6a88 (diff)
downloadvdr-plugin-live-6e6955d282944c5f2e73ab454cfcc374414986c6.tar.gz
vdr-plugin-live-6e6955d282944c5f2e73ab454cfcc374414986c6.tar.bz2
*** empty log message ***
Diffstat (limited to 'schedule.ecpp')
-rw-r--r--schedule.ecpp63
1 files changed, 63 insertions, 0 deletions
diff --git a/schedule.ecpp b/schedule.ecpp
new file mode 100644
index 0000000..8295b80
--- /dev/null
+++ b/schedule.ecpp
@@ -0,0 +1,63 @@
+<%pre>
+#include <boost/lexical_cast.hpp>
+#include <vdr/plugin.h>
+#include <vdr/channels.h>
+#include <vdr/epg.h>
+#include <vdr/config.h>
+int channel_number;
+
+cSchedulesLock schedulesLock;
+const cSchedules* schedules = cSchedules::Schedules(schedulesLock);
+
+
+</%pre>
+<%args>
+channel;
+</%args>
+<html>
+ <head>
+ <title>ecpp-application testproject</title>
+ </head>
+ <body>
+<{
+
+if (channel.empty()) {
+ channel_number = 1;
+} else {
+ try {
+ channel_number = boost::lexical_cast<int>(channel);
+ } catch (boost::bad_lexical_cast const&) {
+}>
+ Channel nicht numerisch!
+<{
+ }
+}>
+
+ Programm für Channel Nummer <$ channel_number $><br/>
+
+<{
+
+ for (cChannel *channel = Channels.First(); channel; channel = Channels.Next(channel)) {
+ if (!channel->GroupSep() && (channel->Number() == channel_number)) {
+
+ const cSchedule *Schedule = schedules->GetSchedule(channel);
+ if (Schedule) {
+ time_t now = time(NULL) - Setup.EPGLinger * 60;
+ for (const cEvent *ev = Schedule->Events()->First(); ev; ev = Schedule->Events()->Next(ev)) {
+}>
+ <$ ev->Title() $><br/>
+
+<{
+ }
+ } else {
+}>
+ Kein Schedule für Channel <$ channel->Number() $>
+<{
+ }
+ }
+ }
+
+}
+}>
+ </body>
+</html>