summaryrefslogtreecommitdiff
path: root/doc/web/homepage/page-php-classes.inc
diff options
context:
space:
mode:
authorDieter Hametner <dh (plus) vdr (at) gekrumbel (dot) de>2008-04-17 01:02:33 +0200
committerDieter Hametner <dh (plus) vdr (at) gekrumbel (dot) de>2008-04-17 01:02:33 +0200
commitbc184315aec2f54c2da20dbea2d80761b29504d5 (patch)
tree5976f8ec4355ec309bd6f3c3739fad292fd92182 /doc/web/homepage/page-php-classes.inc
parentec470074557ed3c6aa486e3a6ae12e537cdfff68 (diff)
downloadvdr-plugin-live-bc184315aec2f54c2da20dbea2d80761b29504d5.tar.gz
vdr-plugin-live-bc184315aec2f54c2da20dbea2d80761b29504d5.tar.bz2
Added dynamic screenshot functionality.
The new page in german is now functionaly complete. A content review needs to be done now.
Diffstat (limited to 'doc/web/homepage/page-php-classes.inc')
-rw-r--r--doc/web/homepage/page-php-classes.inc64
1 files changed, 64 insertions, 0 deletions
diff --git a/doc/web/homepage/page-php-classes.inc b/doc/web/homepage/page-php-classes.inc
new file mode 100644
index 0000000..7ad2341
--- /dev/null
+++ b/doc/web/homepage/page-php-classes.inc
@@ -0,0 +1,64 @@
+<?php
+class Status
+{
+ var $title;
+ var $vers_string;
+ var $vers_number;
+ var $datefmt;
+
+ function Status($title, $vname, $vnum, $datefmt)
+ {
+ $this->title = $title;
+ $this->vers_string = $vname;
+ $this->vers_number = $vnum;
+ $this->datefmt = $datefmt;
+ }
+}
+
+
+class Menu
+{
+ var $urls;
+
+ function Menu($entries)
+ {
+ $this->urls = $entries;
+ }
+}
+
+
+class Screenshots
+{
+ var $images;
+
+ function Screenshots($imgNames)
+ {
+ $this->images = $imgNames;
+ }
+
+ function RandomImg()
+ {
+ $idx = array_rand($this->images);
+ $this->MakeAnchor($this->images[$idx]);
+ }
+
+
+ function AllImg()
+ {
+ foreach($this->images as $img) {
+ $this->MakeAnchor($img);
+ }
+ }
+
+ function MakeAnchor($img)
+ {
+ echo "<a href=\"screenshots.php?img=$img\"><img src=\"img/${img}_thumb.jpg\" alt=\"$img\"/></a>\n";
+ }
+
+ function FullImage($img)
+ {
+ $img = basename($img);
+ echo "<a href=\"screenshots.php\"><img src=\"img/${img}.jpg\" alt=\"img/${img}.jpg\"/ style=\"width: 770px\"></a>\n";
+ }
+}
+?>