Ticket #3654: channel_list.patch

File channel_list.patch, 1.4 KB (added by anonymous, 13 years ago)
  • mythweb/modules/tv/includes/channels.php

     
    5050        $sh = $db->query($sql);
    5151        while ($channel_data = $sh->fetch_assoc())  {
    5252            $Channels[$channel_data['chanid']] = new Channel($channel_data);
    53             if (empty($Callsigns[$channel_data['callsign']]))
    54                 $Callsigns[$channel_data['callsign']] = $channel_data['chanid'];
     53            if (empty($Callsigns[$channel_data['chanid']]))
     54                $Callsigns[$channel_data['chanid']] = $channel_data['callsign'];
    5555        }
    5656        $sh->finish();
    5757    // No channels returned?
  • mythweb/modules/tv/tmpl/default/list.php

     
    5353        $displayed_channels = array();
    5454
    5555    // Go through each channel and load/print its info - use references to avoid "copy" overhead
    56         foreach ($Callsigns as $chanid) {
     56        foreach ($Callsigns as $chanid=>$callsign){
    5757            $channel = $Channels[$chanid];
    5858        // Ignore channels with no number
    5959            if (strlen($channel->channum) < 1)