|
 |
|
ช่วยดูโค็ตให้หน่อย Warning: mkdir() [function.mkdir]: No such file or directory |
|
 |
|
|
 |
 |
|
Code (PHP)
<?
$docid = $_GET["b2"];
$id_cut_a =(substr($docid,-16, 1));
$id_cut_b =(substr($docid,-14, 2));
$id_cut_c =(substr($docid,-11, 2));
$id_cut_d =(substr($docid,-8, 2));
$id_cut_e =(substr($docid,-5, 3));
?>
<?php
//Where'd the files go?
$dep = $_GET["dep"];
$doc_id = $_GET["doc_id"];
$processing = "Processing";
$a = $id_cut_a;
$b = $id_cut_b;
$c = $id_cut_c;
$d = $id_cut_d;
$e = $id_cut_e;
if(!is_dir("isodoc/". $a . "/" . $b . "/". $c . "/". $d . "/". $e . "/". $processing . "/")){
mkdir("isodoc/". $a . "/" . $b . "/". $c . "/". $d . "/". $e . "/". $processing . "/");
}
$uploader->SaveDirectory="isodoc/". $id_cut_a . "/" . $id_cut_b . "/". $id_cut_c . "/". $id_cut_d . "/". $id_cut_e . "/". $processing . "/";
$uploader->Render();
?>
Warning: mkdir() [function.mkdir]: No such file or directory ทำไงหรอครับ ไม่ได้อัฟขึ้น host ไรทีครับ run บน localhost ครับ
Tag : PHP

|
|
 |
 |
 |
 |
Date :
2011-12-29 16:00:31 |
By :
beer656 |
View :
1154 |
Reply :
1 |
|
 |
 |
 |
 |
|
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
วิธีนี้อาจจะไม่เมคเซ้นท์เท่าไหร่ แต่เอาไปเป็นแนวน่ะครับ
โค้ดคุณที่ error เพราะ มันหาโฟลเดอร์ หรือ พาร์ท ไม่เจอครับ
ต้องสร้างทีละชั้น จริงๆแล้วสามารถประยุกต์เป็น loop ได้น่ะครับ
Code (PHP)
if(mkdir("isodoc/".$a)
{
$path = "isodoc/".$a;
if(mkdir($path."/". $b)
{
$path = $path."/".$b;
if(mkdir($path."/".$c)
{
$path = $path."/".$c;
if(mkdir($path."/".$d)
{
$path = $path."/".$d;
if(mkdir($path."/".$e)
{
$path = $path."/".$e;
if(mkdir($path."/".$processing)
{
$path = $path."/".$processing;
}
}
}
}
}
}
|
ประวัติการแก้ไข 2011-12-29 17:38:23 2011-12-29 17:39:05
 |
 |
 |
 |
Date :
2011-12-29 17:37:19 |
By :
mangkunzo |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
|
|
|

|
Load balance : Server 02
|