From 42c62cb041a2b2b95c9cda0c20fcf70334fd244c Mon Sep 17 00:00:00 2001 From: deva Date: Tue, 1 Nov 2011 09:32:21 +0000 Subject: Rewl og krat... needs cleaning up - after port to GIT. --- utils/modules/downloads.php | 33 +++++++++++++++++++++++++++++++-- 1 file changed, 31 insertions(+), 2 deletions(-) (limited to 'utils/modules/downloads.php') diff --git a/utils/modules/downloads.php b/utils/modules/downloads.php index 99e9962..52c6736 100644 --- a/utils/modules/downloads.php +++ b/utils/modules/downloads.php @@ -68,6 +68,21 @@ class DownloadItem { */ } + public function showRef() + { + $str = ""; + + if($this->type == "youtube") { + $str .= "value."\">Video: " . $this->title.""; + } + + if($this->type == "vimeo") { + $str .= "value."\">Video: " . $this->title.""; + } + + return $str; + } + public function show() { global $VIDEO_WIDTH; @@ -254,6 +269,20 @@ class Downloads { */ } + public function showRef($id) + { + $bleh = explode(",", $id); + $gid = $bleh[0]; + $iid = $bleh[1]; + + $str = ""; + if($this->groups[$gid] && $this->groups[$gid]->items[$iid]) { + $str .= $this->groups[$gid]->items[$iid]->showRef(); + } + + return $str; + } + private function read() { $dom = new DomDocument; @@ -284,12 +313,12 @@ class Downloads { } } - ksort($item->sources); + // ksort($item->sources); $group->addItem($item); } } - ksort($group->items); + // ksort($group->items); $this->add($group); } } -- cgit v1.2.3