|
 |
|
ทัมมัย sevrer linux อัพรูปไม่ได้ครับ if($Submit){ $sql="INSERT INTO `user` (`user_name`,`user_pass`,`user_status`) |
|
 |
|
|
 |
 |
|
<?
if($Submit){
$sql="INSERT INTO `user` (`user_name`,`user_pass`,`user_status`) VALUES ('$user_name','$user_pass','$user_status');";
mysql_query($sql);
//....................
$max = mysql_query("select max(user_id) from user");
$id_max = mysql_result($max,0);
//.....................
if(trim($_FILES["m_pic"]["tmp_name"]) != "")
{
$images = $_FILES["m_pic"]["tmp_name"];
$new_images = $_FILES["m_pic"]["name"];
$width=200; //*** Fix Width & Heigh (Autu caculate) ***//
$size=GetimageSize($images);
$height=round($width*$size[1]/$size[0]);
$images_orig = ImageCreateFromJPEG($images);
$photoX = ImagesX($images_orig);
$photoY = ImagesY($images_orig);
$images_fin = ImageCreateTrueColor($width, $height);
ImageCopyResampled($images_fin, $images_orig, 0, 0, 0, 0, $width+1, $height+1, $photoX, $photoY);
ImageJPEG($images_fin,"pic_member/".$new_images);
ImageDestroy($images_orig);
ImageDestroy($images_fin);
//copy($_FILES["m_pic"]["tmp_name"],"pic_member/".$_FILES["m_pic"]["name"]);
}
//.....................
echo $sql2="INSERT INTO `member_detail` (`user_id`,`m_sex`,`m_name`,`m_sername`,`m_position`,`m_institute`,`m_ministry`,`m_tel`,`m_mail`,`m_pic`) VALUES ('$id_max','$m_sex','$m_name','$m_sername','$m_position','$m_institute','$m_ministry','$m_tel','$m_mail','$new_images');";
mysql_query($sql2);
print"<script language=JavaScript type=text/JavaScript> ";
print"alert('คุณได้สมัครเป็นสมาชิกเรียบร้อยแล้วครับ')"; print "</script>";
echo"<meta http-equiv=\"refresh\" content='0;URL=index.php'>";
//...................
}
?>
ทัมมัย sevrer linux อัพรูปไม่ได้ครับ
งง จริงๆ แต่ในเครื่องที่รัน appserv ได้ครับ หรือว่าต้องปรัปเปลี่ยนตรงไหนอีกครับ
ท่านเทพๆ ช่วยหน่อยนะครับ
Tag : - - - -

|
|
 |
 |
 |
 |
Date :
2009-06-05 09:20:33 |
By :
dee_com |
View :
1125 |
Reply :
3 |
|
 |
 |
 |
 |
|
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
น่าจะต้อง CHMOD 777 โฟเดอร์ pic_member ด้วยน่ะครับ เพื่อให้สามารถ Rewrite รูปลงได้ครับ
|
 |
 |
 |
 |
Date :
2009-06-05 09:23:51 |
By :
webmaster |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
ผมทัม CHMOD 777 โฟเดอร์ pic_member แล้วครับ แต่ยังไม่ได้
|
 |
 |
 |
 |
Date :
2009-06-05 11:22:14 |
By :
dee_com |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
คิดว่าขนาดน่าจะใหญ่เกิน server กำหนด
|
 |
 |
 |
 |
Date :
2009-06-05 14:08:35 |
By :
plakrim |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
|
|
|

|
Load balance : Server 01
|