| 1 | 
<?php | 
|---|
| 2 | 
 | 
|---|
| 3 | 
 | 
|---|
| 4 | 
 | 
|---|
| 5 | 
 | 
|---|
| 6 | 
 | 
|---|
| 7 | 
 | 
|---|
| 8 | 
 | 
|---|
| 9 | 
 | 
|---|
| 10 | 
 | 
|---|
| 11 | 
 | 
|---|
| 12 | 
 | 
|---|
| 13 | 
 | 
|---|
| 14 | 
 | 
|---|
| 15 | 
 | 
|---|
| 16 | 
 | 
|---|
| 17 | 
 | 
|---|
| 18 | 
 | 
|---|
| 19 | 
include("./foltialib.php"); | 
|---|
| 20 | 
$con = m_connect(); | 
|---|
| 21 | 
 | 
|---|
| 22 | 
 | 
|---|
| 23 | 
if ($useenvironmentpolicy == 1){ | 
|---|
| 24 | 
if (!isset($_SERVER['PHP_AUTH_USER'])) { | 
|---|
| 25 | 
    header("WWW-Authenticate: Basic realm=\"foltia\""); | 
|---|
| 26 | 
    header("HTTP/1.0 401 Unauthorized"); | 
|---|
| 27 | 
    redirectlogin(); | 
|---|
| 28 | 
    exit; | 
|---|
| 29 | 
} else { | 
|---|
| 30 | 
login($con,$_SERVER['PHP_AUTH_USER'],$_SERVER['PHP_AUTH_PW']); | 
|---|
| 31 | 
} | 
|---|
| 32 | 
} | 
|---|
| 33 | 
 | 
|---|
| 34 | 
?> | 
|---|
| 35 | 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> | 
|---|
| 36 | 
<html lang="ja"> | 
|---|
| 37 | 
<head> | 
|---|
| 38 | 
<meta http-equiv="Content-Type" content="text/html; charset=EUC-JP"> | 
|---|
| 39 | 
<meta http-equiv="Content-Style-Type" content="text/css"> | 
|---|
| 40 | 
<link rel="stylesheet" type="text/css" href="graytable.css">  | 
|---|
| 41 | 
<title>foltia</title> | 
|---|
| 42 | 
</head> | 
|---|
| 43 | 
 | 
|---|
| 44 | 
<?php | 
|---|
| 45 | 
 | 
|---|
| 46 | 
 | 
|---|
| 47 | 
 | 
|---|
| 48 | 
$lim = 1000; | 
|---|
| 49 | 
 | 
|---|
| 50 | 
$p = getgetnumform(p); | 
|---|
| 51 | 
 | 
|---|
| 52 | 
list($st,$p,$p2) = number_page($p,$lim); | 
|---|
| 53 | 
 | 
|---|
| 54 | 
 | 
|---|
| 55 | 
$now = date("YmdHi");    | 
|---|
| 56 | 
 | 
|---|
| 57 | 
$query = " | 
|---|
| 58 | 
 | 
|---|
| 59 | 
 | 
|---|
| 60 | 
 | 
|---|
| 61 | 
 | 
|---|
| 62 | 
 | 
|---|
| 63 | 
 | 
|---|
| 64 | 
; | 
|---|
| 65 | 
 | 
|---|
| 66 | 
$rs = sql_query($con, $query, "DBクエリに失敗しました"); | 
|---|
| 67 | 
$rowdata = $rs->fetch(); | 
|---|
| 68 | 
          if (! $rowdata) { | 
|---|
| 69 | 
                die_exit("番組データがありません<BR>"); | 
|---|
| 70 | 
                } | 
|---|
| 71 | 
 | 
|---|
| 72 | 
    $query2 = " | 
|---|
| 73 | 
SELECT COUNT(*) AS cnt FROM foltia_program  | 
|---|
| 74 | 
    "; | 
|---|
| 75 | 
$rs2 = sql_query($con, $query2, "DBクエリに失敗しました"); | 
|---|
| 76 | 
$rowdata2 = $rs2->fetch(); | 
|---|
| 77 | 
          if (! $rowdata2) { | 
|---|
| 78 | 
                die_exit("番組データがありません<BR>"); | 
|---|
| 79 | 
          } | 
|---|
| 80 | 
 | 
|---|
| 81 | 
$dtcnt =  $rowdata2[0]; | 
|---|
| 82 | 
 | 
|---|
| 83 | 
?> | 
|---|
| 84 | 
 | 
|---|
| 85 | 
<body BGCOLOR="#ffffff" TEXT="#494949" LINK="#0047ff" VLINK="#000000" ALINK="#c6edff" > | 
|---|
| 86 | 
<div align="center"> | 
|---|
| 87 | 
 | 
|---|
| 88 | 
<?php  | 
|---|
| 89 | 
printhtmlpageheader(); | 
|---|
| 90 | 
?> | 
|---|
| 91 | 
  <p align="left"><font color="#494949" size="6">番組一覧</font></p> | 
|---|
| 92 | 
  <hr size="4"> | 
|---|
| 93 | 
<p align="left">全番組リストを表示します。</p> | 
|---|
| 94 | 
 | 
|---|
| 95 | 
<?php | 
|---|
| 96 | 
         | 
|---|
| 97 | 
$maxcols = $rs->columnCount(); | 
|---|
| 98 | 
     | 
|---|
| 99 | 
 | 
|---|
| 100 | 
echo "<div id=contents class=autopagerize_page_element />"; | 
|---|
| 101 | 
?> | 
|---|
| 102 | 
 | 
|---|
| 103 | 
  <table BORDER="0" CELLPADDING="0" CELLSPACING="2" WIDTH="100%"> | 
|---|
| 104 | 
    <thead> | 
|---|
| 105 | 
        <tr> | 
|---|
| 106 | 
            <th align="left">TID</th> | 
|---|
| 107 | 
            <th align="left">タイトル</th> | 
|---|
| 108 | 
            <th align="left">MPEG4リンク</th> | 
|---|
| 109 | 
        </tr> | 
|---|
| 110 | 
    </thead> | 
|---|
| 111 | 
     | 
|---|
| 112 | 
    <tbody> | 
|---|
| 113 | 
        <?php | 
|---|
| 114 | 
             | 
|---|
| 115 | 
 | 
|---|
| 116 | 
  do { | 
|---|
| 117 | 
                echo("<tr>\n"); | 
|---|
| 118 | 
 | 
|---|
| 119 | 
                 | 
|---|
| 120 | 
                    echo("<td><a href=\"reserveprogram.php?tid=" . | 
|---|
| 121 | 
                    htmlspecialchars($rowdata[0])  . "\">" . | 
|---|
| 122 | 
                    htmlspecialchars($rowdata[0]) . "</a></td>\n"); | 
|---|
| 123 | 
                       | 
|---|
| 124 | 
                        echo("<td><a href=\"http://cal.syoboi.jp/progedit.php?TID=" . | 
|---|
| 125 | 
                    htmlspecialchars($rowdata[0])  . "\" target=\"_blank\">" . | 
|---|
| 126 | 
                    htmlspecialchars($rowdata[1]) . "</a></td>\n"); | 
|---|
| 127 | 
                    print "<td><A HREF = \"showlibc.php?tid=".htmlspecialchars($rowdata[0])."\">mp4</A></td>\n"; | 
|---|
| 128 | 
 | 
|---|
| 129 | 
                echo("</tr>\n"); | 
|---|
| 130 | 
    } while ($rowdata = $rs->fetch()); | 
|---|
| 131 | 
 | 
|---|
| 132 | 
        ?> | 
|---|
| 133 | 
 | 
|---|
| 134 | 
    </tbody> | 
|---|
| 135 | 
</table> | 
|---|
| 136 | 
 | 
|---|
| 137 | 
<?php | 
|---|
| 138 | 
 | 
|---|
| 139 | 
 | 
|---|
| 140 | 
 | 
|---|
| 141 | 
page_display("",$p,$p2,$lim,$dtcnt,""); | 
|---|
| 142 | 
 | 
|---|
| 143 | 
 | 
|---|
| 144 | 
?> | 
|---|
| 145 | 
</body> | 
|---|
| 146 | 
</html> | 
|---|
| 147 | 
 | 
|---|