svnno****@sourc*****
svnno****@sourc*****
2011年 5月 5日 (木) 02:05:28 JST
Revision: 31 http://sourceforge.jp/projects/smartupload/svn/view?view=rev&revision=31 Author: hryksbt Date: 2011-05-05 02:05:28 +0900 (Thu, 05 May 2011) Log Message: ----------- download_file.phpにコメント表示を追加し、表での表示に変更 Modified Paths: -------------- trunk/SmartUpload/download_file.php trunk/SmartUpload/upload_form.php trunk/SmartUpload/user_form.php Added Paths: ----------- trunk/SmartUpload/main.php -------------- next part -------------- Modified: trunk/SmartUpload/download_file.php =================================================================== --- trunk/SmartUpload/download_file.php 2011-05-04 15:25:06 UTC (rev 30) +++ trunk/SmartUpload/download_file.php 2011-05-04 17:05:28 UTC (rev 31) @@ -2,7 +2,7 @@ /* * SmartUpload/download_file.php * @author Hiroyuki Shibata - * 2011/04/26 + * 2011/05/04 * Rev 1.0 * */ @@ -15,7 +15,7 @@ </head> <body> <p> - <b>File Downloader</b> + <b>ダウンロード</b> </p> <?php @@ -26,23 +26,28 @@ require_once ("include/database.php"); //session_start(); - $sql ='select * from data_info'; - - foreach ($db->query($sql) as $row) { - - ?> - <a href="./data/ - <?php print($row['filename']." "); ?> - "> - <?php print($row['filename']." "); ?> - </a> - <?php - - print($row['uploaddate']." "); - print($row['data_size']."<br>"); - + $sql = $db->prepare('select * from data_info'); + $sql->execute(); + ?> + <table border> + <tr> + <th>ファイル名</th> + <th>アップロード年月日&時刻</th> + <th>サイズ</th> + <th>コメント</th> + </tr> + <?php + while($row = $sql->fetch(PDO::FETCH_ASSOC)) { + ?> + <tr> + <td><a href="./data/ <?php print($row['filename']); ?> "><?php print($row['filename']); ?></a></td> + <td><?php print($row['uploaddate']); ?></td> + <td><?php print($row['data_size']); ?> </td> + <td><?php print($row["comment"]); ?></td> + </tr> + <?php } - ?> + </table> </body> </html> \ No newline at end of file Added: trunk/SmartUpload/main.php =================================================================== --- trunk/SmartUpload/main.php (rev 0) +++ trunk/SmartUpload/main.php 2011-05-04 17:05:28 UTC (rev 31) @@ -0,0 +1,10 @@ +<?php +/* + * SmartUpload/main.php + * @author Hiroyuki Shibata + * 2011/05/4 + * Rev 1.0 + * + */ + session_start(); +?> \ No newline at end of file Modified: trunk/SmartUpload/upload_form.php =================================================================== --- trunk/SmartUpload/upload_form.php 2011-05-04 15:25:06 UTC (rev 30) +++ trunk/SmartUpload/upload_form.php 2011-05-04 17:05:28 UTC (rev 31) @@ -2,7 +2,7 @@ /* * SmartUpload/upload_form.php * @author Hiroyuki Shibata - * 2011/04/26 + * 2011/05/4 * Rev 1.0 * */ @@ -15,9 +15,17 @@ <title>SmartUpload</title> </head> <body> - <form method="post" enctype="multipart/form-data" - action="upload_file.php"> - <input type="file" name="upfile"> <input type="submit" value="アップロード"> + <p> + <b>アップロード</b> + </p> + <form method="post" enctype="multipart/form-data" action="upload_file.php"> + <pre> +コンテンツ名 :<input type="text" name="mail"> ※ 全角32文字以内<br> +カテゴリ :<input type="text" name="mail"><br> +コメント :<input type="text" name="mail"> ※ 全角512文字以内<br> +ファイル :<input type="file" name="upfile"><br> +<input type="submit" value="アップロード"> <input type="reset" value="リセット"> + </pre> </form> </body> </html> Modified: trunk/SmartUpload/user_form.php =================================================================== --- trunk/SmartUpload/user_form.php 2011-05-04 15:25:06 UTC (rev 30) +++ trunk/SmartUpload/user_form.php 2011-05-04 17:05:28 UTC (rev 31) @@ -2,7 +2,7 @@ /* * SmartUpload/user_form.php * @author Hiroyuki Shibata - * 2011/04/26 + * 2011/05/01 * Rev 1.0 * */ @@ -19,10 +19,9 @@ </p> <form name="user_form" action="./user_add.php" method="post"> <pre> -ID(アカウント) :<input type="text" name="id"> ※ 32文字以内<br> -パスワード :<input type="password" name="pass"> ※ 32文字以内<br> -氏名 :<input type="text" name="name"> ※ 64文字以内<br> - +ID(アカウント) :<input type="text" name="id"> ※ 半角32文字以内<br> +パスワード :<input type="password" name="pass"> ※ 半角英数字32文字以内<br> +氏名 :<input type="text" name="name"> ※ 全角32文字以内(半角64文字以内)<br> 国 :<select name="country"> <option value="001">アメリカ</option> <option value="002">日本</option> @@ -31,12 +30,11 @@ <option value="005">インドネシア</option> <option value="006">ブラジル</option> </select> - <br> -メールアドレス :<input type="text" name="mail"> ※ 64文字以内<br> +メールアドレス :<input type="text" name="mail"> ※ 半角64文字以内<br> + +<input type="submit" class="update" value="登録" /> <input type="reset" value="リセット"> </pre> - <input type="submit" class="update" value="登録" /> <input type="reset" - value="リセット"> </form> </body> </html>