[ Index ] |
PHP Cross Reference of phpwcms V1.5.0 _r431 (28.01.12) |
[Summary view] [Print] [Text view]
1 <?php 2 /************************************************************************************* 3 Copyright notice 4 5 (c) 2002-2012 Oliver Georgi <oliver@phpwcms.de> // All rights reserved. 6 7 This script is part of PHPWCMS. The PHPWCMS web content management system is 8 free software; you can redistribute it and/or modify it under the terms of 9 the GNU General Public License as published by the Free Software Foundation; 10 either version 2 of the License, or (at your option) any later version. 11 12 The GNU General Public License can be found at http://www.gnu.org/copyleft/gpl.html 13 A copy is found in the textfile GPL.txt and important notices to the license 14 from the author is found in LICENSE.txt distributed with these scripts. 15 16 This script is distributed in the hope that it will be useful, but WITHOUT ANY 17 WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A 18 PARTICULAR PURPOSE. See the GNU General Public License for more details. 19 20 This copyright notice MUST APPEAR in all copies of the script! 21 *************************************************************************************/ 22 23 // ---------------------------------------------------------------- 24 // obligate check for phpwcms constants 25 if (!defined('PHPWCMS_ROOT')) { 26 die("You Cannot Access This Script Directly, Have a Nice Day."); 27 } 28 // ---------------------------------------------------------------- 29 30 31 //Listing eventuell im Verzeichnis enthaltener Dateien 32 $file_sql = "SELECT * FROM ".DB_PREPEND."phpwcms_file WHERE f_pid=0 AND f_uid=".$_SESSION["wcs_user_id"]. 33 " AND f_kid=1 AND f_trash=0 ORDER BY f_sort, f_name"; 34 if($file_result = mysql_query($file_sql, $db) or die ("error while listing files")) { 35 $file_durchlauf = 0; 36 $zieldatei = "phpwcms.php?do=files&f=0"; 37 while($file_row = mysql_fetch_array($file_result)) { 38 $filename = html_specialchars($file_row["f_name"]); 39 if(!$file_durchlauf) { //Aufbau der Zeile zum Einfließen der Filelisten-Tavbelle 40 echo "<tr bgcolor=\"#F5F8F9\"><td colspan=\"2\"><table width=\"538\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n"; 41 } else { 42 echo "<tr bgcolor=\"#FFFFFF\"><td colspan=\"5\"><img src=\"img/leer.gif\" height=\"1\" width=\"1\"></td></tr>\n"; 43 } 44 echo "<tr>\n"; 45 echo "<td width=\"19\" class=\"msglist\"><img src=\"img/leer.gif\" height=\"1\" width=\"19\" border=\"0\"></td>\n"; 46 echo "<td width=\"13\" class=\"msglist\">"; 47 echo "<img src=\"img/icons/small_".extimg($file_row["f_ext"])."\" border=\"0\" "; 48 echo 'onmouseover="Tip(\'ID: '.$file_row["f_id"].'<br>Sort: '.$file_row["f_sort"]; 49 echo '<br>Name: '.html_specialchars($file_row["f_name"]); 50 if($file_row["f_copyright"]) { 51 echo '<br>©: '.html_specialchars($file_row["f_copyright"]); 52 } 53 echo '\');" onmouseout="UnTip()" alt=""'; 54 echo " /></td>\n"; 55 echo "<td width=\"406\" class=\"msglist\"><img src=\"img/leer.gif\" height=\"1\" width=\"5\" />"; 56 echo "<a href=\"fileinfo.php?fid=".$file_row["f_id"]; 57 echo "\" target=\"_blank\" onclick=\"flevPopupLink(this.href,'filedetail','scrollbars=yes,resizable=yes,width=500,height=400',1);return document.MM_returnValue;\">"; 58 echo $filename."</a></td>\n"; 59 //Aufbauen Buttonleiste für jeweilige Datei 60 echo "<td width=\"100\" align=\"right\" class=\"msglist\">"; 61 //Button zum Downloaden der Datei 62 echo "<a href=\"include/inc_act/act_download.php?dl=".$file_row["f_id"]. 63 "\" target=\"_blank\" title=\"".$BL['be_fprivfunc_dlfile'].": ".$filename."\">". 64 "<img src=\"img/button/download_disc.gif\" border=\"0\"></a>"; 65 //Button zum Erzeugen eines Neuen Unterverzeichnisses 66 if($cutID == $file_row["f_id"]) { 67 echo "<img src=\"img/button/cut_13x13_1.gif\" border=\"0\" title=\"".$BL['be_fprivfunc_clipfile'].": ".$filename."\">"; 68 } else { 69 echo "<a href=\"".$zieldatei."&cut=".$file_row["f_id"]."\" title=\"".$BL['be_fprivfunc_cutfile'].": ".$filename."\">"; 70 echo "<img src=\"img/button/cut_13x13_0.gif\" border=\"0\"></a>"; 71 } 72 //Button zum Bearbeiten der Dateiinformationn 73 echo "<a href=\"".$zieldatei."&editfile=".$file_row["f_id"]."\" title=\"".$BL['be_fprivfunc_editfile'].": ".$filename."\">"; 74 echo "<img src=\"img/button/edit_22x13.gif\" border=\"0\"></a>"; 75 //Button zum Umschalten zwischen Aktiv/Inaktiv 76 echo "<a href=\"include/inc_act/act_file.php?aktiv=".$file_row["f_id"].'%7C'.true_false($file_row["f_aktiv"]). 77 "\" title=\"".$BL['be_fprivfunc_cactivefile'].": ".$filename."\">"; 78 echo "<img src=\"img/button/aktiv_12x13_".$file_row["f_aktiv"].".gif\" border=\"0\"></a>"; 79 //Button zum Umschalten zwischen Public/Non-Public 80 echo "<a href=\"include/inc_act/act_file.php?public=".$file_row["f_id"].'%7C'.true_false($file_row["f_public"]). 81 "\" title=\"".$BL['be_fprivfunc_cpublicfile'].": ".$filename."\">"; 82 echo "<img src=\"img/button/public_12x13_".$file_row["f_public"].".gif\" border=\"0\"></a>"; 83 echo "<img src=\"img/leer.gif\" width=\"5\" height=\"1\">"; //Spacer 84 //Button zum Löschen der Datei 85 echo "<a href=\"include/inc_act/act_file.php?trash=".$file_row["f_id"].'%7C'."1". 86 "\" title=\"".$BL['be_fprivfunc_movetrash'].": ".$filename."\" onclick=\"return confirm('".$BL['be_fprivfunc_jsmovetrash1']. 87 "\\n[".$filename."] \\n".$BL['be_fprivfunc_jsmovetrash2']."');\">". 88 "<img src=\"img/button/trash_13x13_1.gif\" border=\"0\"></a>"; 89 echo "<img src=\"img/leer.gif\" width=\"2\" height=\"1\">"; //Spacer 90 echo "</td>\n"; 91 //Ende Aufbau 92 echo "</tr>\n"; 93 94 if($_SESSION["wcs_user_thumb"]) { 95 96 // now try to get existing thumbnails or if not exists 97 // build new based on default thumbnail listing sizes 98 99 // build thumbnail image name 100 $thumb_image = get_cached_image( 101 array( "target_ext" => $file_row["f_ext"], 102 "image_name" => $file_row["f_hash"] . '.' . $file_row["f_ext"], 103 "thumb_name" => md5($file_row["f_hash"].$phpwcms["img_list_width"].$phpwcms["img_list_height"].$phpwcms["sharpen_level"]) 104 ) 105 ); 106 107 if($thumb_image != false) { 108 109 echo "<tr>\n"; 110 echo "<td width=\"19\"><img src=\"img/leer.gif\" height=\"1\" width=\"1\" border=\"0\"></td>\n"; 111 echo "<td width=\"13\"><img src=\"img/leer.gif\" height=\"1\" width=\"1\" border=\"0\"></td>\n<td width=\""; 112 echo "406\"><img src=\"img/leer.gif\" height=\"1\" width=\"6\"><a href=\"fileinfo.php?fid="; 113 echo $file_row["f_id"]."\" target=\"_blank\" onclick=\"flevPopupLink(this.href,'filedetail','scrollbars="; 114 echo "yes,resizable=yes,width=500,height=400',1); return document.MM_returnValue;\">"; 115 echo '<img src="'.PHPWCMS_IMAGES . $thumb_image[0] .'" border="0" '.$thumb_image[3].'></a></td>'."\n"; 116 echo "<td width=\"100\"><img src=\"img/leer.gif\" height=\"1\" width=\"1\" border=\"0\"></td>\n</tr>\n"; 117 echo "<tr><td colspan=\"4\"><img src=\"img/leer.gif\" height=\"2\" width=\"1\" border=\"0\"></td>\n</tr>\n"; 118 119 } 120 121 } 122 $file_durchlauf++; 123 } 124 if($file_durchlauf) { //Abschluss der Filelisten-Tabelle 125 echo "</table>\n"; 126 echo "<tr bgcolor=\"#F5F8F9\"><td colspan=\"2\"><img src=\"img/leer.gif\" height=\"1\" width=\"1\"></td></tr>\n"; //Abstand vor 127 } 128 } //Ende Liste Dateien 129 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Sun Jan 29 16:31:14 2012 | Cross-referenced by PHPXref 0.7.1 |