diff options
author | Alib <aliboba@free.fr> | 2010-03-25 08:49:14 +0100 |
---|---|---|
committer | Alib <aliboba@free.fr> | 2010-03-25 08:49:14 +0100 |
commit | e3b61fcf61d809dfecdf54ae6664e71ee1c65b47 (patch) | |
tree | 0b7156d018f0600a7eebb46e75aa6f991bd23941 | |
parent | 024687631f1fa88d9d56fb2175c78686d5848382 (diff) | |
download | istreamdev-e3b61fcf61d809dfecdf54ae6664e71ee1c65b47.tar.gz istreamdev-e3b61fcf61d809dfecdf54ae6664e71ee1c65b47.tar.bz2 |
show full day epg
-rw-r--r-- | index.php | 2 | ||||
-rw-r--r-- | js/istreamdev.js | 19 |
2 files changed, 17 insertions, 4 deletions
@@ -232,7 +232,7 @@ include ('bin/auth.php'); <li><span class="timertitle">Select Time:</span></li> <li class="arrow"><a href="javascript:openSelectTime('layer_epgtime')" class="abutton" id="a_starttime"><span id="layer_epgtime" class="menuname"></span></a></li> </ul> - <input name="epg_time" type="hidden" id="epg_time" value="all" /> + <input name="epg_time" type="hidden" id="epg_time" value="" /> <ul class="rounded" ref="submitbut"><li><center><a href="#" class="submit_epg">Get Programs</a></center></li></ul> </form> </div> diff --git a/js/istreamdev.js b/js/istreamdev.js index 315ebff..80c51f0 100644 --- a/js/istreamdev.js +++ b/js/istreamdev.js @@ -975,8 +975,10 @@ $('.submit_epg').tap(function(event) { if ( channel == "all" ) {
programs = 2;
}
- else {
- programs = 10;
+ else if ( time == "" ) {
+ programs = "day";
+ } else {
+ programs = 20;
}
get_epg(channel,time,day,programs);
$(this).removeClass('active');
@@ -1029,10 +1031,21 @@ var dataString = 'action=getEpg&channel=' + channel + '&time=' + time + '&day=' $.getJSON("bin/backend.php",
dataString,
function(data) {
+ var k=1;
$.each(data.channel, function(i,channel){
+ k++;
$('#epglist #ul_epglist').append('<li class="sep">' + channel.name + '</li>');
$.each(channel.epg, function(j,epg){
- $('#epglist #ul_epglist').append('<li><a href="#"><span class="epgtime">' + epg.time + '</span><span class="epgname">' + epg.title + '</span></a></li>');
+ if ( k > 10 ) {
+ togglestatus = 'toggle';
+ }
+ else
+ {
+ togglestatus = '';
+ }
+ $('#epglist #ul_epglist').append('<li rel="' + togglestatus + '><a href="#"><span class="epgtime">' + epg.time + '</span><span class="epgname">' + epg.title + '</span></a></li>');
+
+ k++;
});
});
json_complete('#epglist','cube');
|