Tv.php
authorAlan Knowles <alan@akbkhome.com>
Tue, 30 Aug 2011 13:31:21 +0000 (21:31 +0800)
committerAlan Knowles <alan@akbkhome.com>
Tue, 30 Aug 2011 13:31:21 +0000 (21:31 +0800)
Tv.php

diff --git a/Tv.php b/Tv.php
index 711d470..8f3b6fb 100644 (file)
--- a/Tv.php
+++ b/Tv.php
@@ -114,10 +114,21 @@ class XML_Tv
             // loook for... <BR>2007-12-31 Mon
             $start = preg_match('/<BR>([0-9]{4}-[0-9]{2}-[0-9]{2}) Mon/i', $odata, $matches);
             $start = $matches[1]; // first monday..
+            
+            $use_cols = 1;
             foreach($days as $i=>$ddata) {
+                
+                
+                
                 $cols = explode(',',$cinfo['htmlcols']);
                 $dn = strtotime($start) + (($i ) * 24 * 60 * 60 );
-                $this->schedule[$chid][strtotime($start) + (($i ) * 24 * 60 * 60 )]  = $this->$method($ddata,$cols,date('Y-m-d',$dn));
+                $res =  $this->$method($ddata,$cols,date('Y-m-d',$dn));
+                if (is_string($res)) {
+                    $start = $res;
+                     $use_cols =0;
+                    continue;
+                }
+                $this->schedule[$chid][strtotime($start) + (($i *  $use_cols ) * 24 * 60 * 60 )]  =
             }
             return;