diff options
Diffstat (limited to 'js')
-rw-r--r-- | js/istreamdev.js | 26 |
1 files changed, 24 insertions, 2 deletions
diff --git a/js/istreamdev.js b/js/istreamdev.js index 091b145..12fd27b 100644 --- a/js/istreamdev.js +++ b/js/istreamdev.js @@ -167,7 +167,7 @@ function gen_categories() { //Gen Channels
function gen_channels(category) {
$("#chan_menu").html('');
- var dataString = "action=getTvChan&cat=" + category;
+ var dataString = "action=getTvChan&cat=" + escape(category);
//Json call to get category array
$.getJSON("bin/backend.php",
dataString,
@@ -674,6 +674,7 @@ function gen_formchanlist() { $.getJSON("bin/backend.php",
dataString,
function(data) {
+ $('#jqt').data('channellist',data);
$.each(data.category, function(i,category){
$('#timer_chan').append('<optgroup label="' + category.name + '">');
var catname = category.name;
@@ -739,4 +740,25 @@ function showStatus( timeout, message ) { $('#timer_status').hide();
}
}
-// [/TIMER SECTION]
\ No newline at end of file +// [/TIMER SECTION]
+
+// [EPG SECTION]
+function gen_epgchanlist() {
+ data = $('#jqt').data('channellist');
+ $.each(data.category, function(i,category){
+ $('#epg_chan').append('<optgroup label="' + category.name + '">');
+ var catname = category.name;
+ $.each(category.channel, function(j, channel){
+ $('#epg_chan optgroup[label="' + catname +'"]').append('<option value="' + channel.number + '">' + channel.name +'</option>');
+ });
+ $('#epg_chan').append('</optgroup>');
+ });
+}
+
+// check if chan is slected
+function epg_selectchan() {
+ selectedchan = $('#epg_chan').val();
+ alert(selectedchan);
+}
+
+// [/EPG SECTION]
\ No newline at end of file |