[$ include( catfile( get_setting("dir_templates"), "tpl_header.html") ) $]


<!-- care to subscribe to a channel we don't know about? -->
<br /><table cellspacing="8" cellpadding="4" border="0" align="center"><tr align="center"><td bgcolor="#cccccc">
   <form action="my_channels.html" method="POST" style="margin:0">
   <table width="100%" cellpadding="5" cellspacing="1" border="0"><tr align="center">
      <td bgcolor="#ffffff"><small>If you know the address to<br />another channel, enter it here:</small></td>
      <td bgcolor="#ffffff"><input type="text" name="add_url" value="http://" size="35" /><br /><small><small>TIP: <a href="http://www.disobey.com/amphetadesk/finding_more.html">Finding More Channels</a></small></small></td>
      <td bgcolor="#ffffff"><input type="submit" name="submit" value="Add This Channel" /></td>
   </tr></table>
   </form>
</td></tr></table>


<!-- begin the instructions for how to use this page. -->
<form action="my_channels.html" method="POST" style="margin:0">
<table cellspacing="8" cellpadding="4" border="0" width="90%" align="center"><tr align="center"><td>
   <table width="100%"><tr><td align="center">Below are the [$ count_my_channels $] channels that you have subscribed to.
   <br /><strong>To remove channels</strong>, check its box and then the "Remove" button.</td></tr></table>
   <input type="submit" name="remove" value="Remove the Checked Channels" />
</td></tr></table>


<!-- begin our silly table that creates a grey highlight. -->
<table width="90%" cellpadding="0" cellspacing="0" border="0" align="center"><tr><td bgcolor="#cccccc">

    <!-- header bar for columnar explanations. big words! -->
    <table width="100%" cellpadding="5" cellspacing="1" border="0">
    <tr><td bgcolor="#ffcc33" align="center"><small><strong>Delete?</strong></small></td><td bgcolor="#ffcc33"><small><strong>Name / Description</strong></small></td><td bgcolor="#ffcc33">&nbsp;</td><td bgcolor="#ffcc33">&nbsp;</td></tr>


 [$ # display each channel that has been subscribed too.
    my @my_channels = get_my_sorted_channels("title", "data");

    # get the user's window target preference (which controls
    # whether links should open up in the current or a new window.
    my $link_target = get_setting( "user_link_target" );

    # and display the HTML for each subscription.
    foreach my $my_channel (@my_channels) {

       # if we just imported a load of channels, then date_downloaded
       # has not yet been set, so we create a dummy entry for it.
       my $date_downloaded = $my_channel->{date_downloaded} || "This channel has not yet been downloaded.";

       # display each channel table row.
       to_browser(qq{\n});
       to_browser(qq{    <tr valign="top" align="center">\n});
       to_browser(qq{      <td bgcolor="#ffffff"><input type="checkbox" name="del_urls" value="$my_channel->{xmlurl}" /></td>\n});
       to_browser(qq{      <td bgcolor="#ffffff" align="left"><a href="$my_channel->{htmlurl}" target="$link_target"><strong>$my_channel->{title}</strong></a><br /><font color="#666666"><small><strong>Added:</strong> $my_channel->{date_added}. <strong>Last Downloaded:</strong> $date_downloaded</small></font><br />$my_channel->{description}</td>\n});
       to_browser(qq{      <td bgcolor="#ffffff"><a href="$my_channel->{xmlurl}" target="$link_target"><img src="/images/xml.gif" width="36" height="14" alt="View the raw XML source of '$my_channel->{title}'" border="0" /></a></td>\n});
       to_browser(qq{      <td bgcolor="#ffffff"><a href="$my_channel->{htmlurl}" target="$link_target"><img src="/images/globe.gif" width="13" height="13" alt="Go to the '$my_channel->{title}' Site" border="0" /></a></td>\n});
       to_browser(qq{    </tr>\n});
    }

    # and spit it out.
    $OUT = send_to_browser;
 $]


    <!-- footer bar for columnar explanations. big words! -->
    <tr><td bgcolor="#ffcc33" align="center"><small><strong>Delete?</strong></small></td><td bgcolor="#ffcc33"><small><strong>Name / Description</strong></small></td><td bgcolor="#ffcc33">&nbsp;</td><td bgcolor="#ffcc33">&nbsp;</td></tr>
    </table>


<!-- end silliness -->
</td></tr></table>


<!-- end the instructions for how to use this page. -->
<table cellspacing="8" cellpadding="4" border="0" width="90%" align="center"><tr align="center"><td>
   <input type="submit" name="remove" value="Remove the Checked Channels" />
   <table width="100%"><tr><td align="center">Above are the [$ count_my_channels $] channels that you have subscribed to.
   <br /><strong>To remove channels</strong>, check its box and then the "Remove" button.</td></tr></table>
</td></tr></table>
</form>


<!-- care to subscribe to a channel we don't know about? -->
<br /><table cellspacing="8" cellpadding="4" border="0" align="center"><tr align="center"><td bgcolor="#cccccc">
   <form action="my_channels.html" method="POST" style="margin:0">
   <table width="100%" cellpadding="5" cellspacing="1" border="0"><tr align="center">
      <td bgcolor="#ffffff"><small>If you know the address to<br />another channel, enter it here:</small></td>
      <td bgcolor="#ffffff"><input type="text" name="add_url" value="http://" size="35" /><br /><small><small>TIP: <a href="http://www.disobey.com/amphetadesk/finding_more.html">Finding More Channels</a></small></small></td>
      <td bgcolor="#ffffff"><input type="submit" name="submit" value="Add This Channel" /></td>
   </tr></table>
   </form>
</td></tr></table>


[$ include( catfile( get_setting("dir_templates"), "tpl_footer.html") ) $]
