php IHDR w Q )Ba pHYs sRGB gAMA a IDATxMk\U s&uo,mD )Xw+e?tw.oWp;QHZnw`gaiJ9̟灙a=nl[ ʨ G;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ y H@E7j 1j+OFRg}ܫ;@Ea~ j`u'o> j- $_q?qS XzG'ay
files >> /var/www/html/outlet/pusat/ |
files >> //var/www/html/outlet/pusat/fungsi_thumb.php |
<?php // Upload gambar untuk item function UploadItem($fupload_name){ //direktori gambar $vdir_upload = "../../../images/item/"; $vfile_upload = $vdir_upload . $fupload_name; //Simpan gambar dalam ukuran sebenarnya move_uploaded_file($_FILES["fupload"]["tmp_name"], $vfile_upload); $ext= end(explode('.', $_FILES['fupload']['name'])); //identitas file asli //untuk membuat ukuran small if($ext=="jpg" || $ext=="jpeg" ) { $im_src = imagecreatefromjpeg($vfile_upload); } else if($ext=="png") { $im_src = imagecreatefrompng($vfile_upload); } else if($ext=="gif") { $im_src = imagecreatefromgif($vfile_upload); } else { $im_src = imagecreatefrombmp($vfile_upload); } $src_width = imageSX($im_src); $src_height = imageSY($im_src); //Simpan dalam versi small 200 pixel //Set ukuran gambar hasil perubahan $dst_width =200; $dst_height = ($dst_width/$src_width)*$src_height; $im = imagecreatetruecolor($dst_width,$dst_height); imagecopyresampled($im, $im_src, 0, 0, 0, 0, $dst_width, $dst_height, $src_width, $src_height); $dst_width2 =50; $dst_height2 = ($dst_width2/$src_width)*$src_height; //proses perubahan ukuran $im2 = imagecreatetruecolor($dst_width2,$dst_height2); imagecopyresampled($im2, $im_src, 0, 0, 0, 0, $dst_width2, $dst_height2, $src_width, $src_height); //Simpan gambar imagejpeg($im,$vdir_upload . "medium_" . $fupload_name); imagejpeg($im2,$vdir_upload . "small_" . $fupload_name); //Hapus gambar di memori komputer imagedestroy($im_src); imagedestroy($im); imagedestroy($im2); } // Upload gambar untuk customer function UploadCustomer1($fupload_name){ //direktori gambar $vdir_upload = "../../../images/customer/"; $vfile_upload = $vdir_upload . $fupload_name; //Simpan gambar dalam ukuran sebenarnya move_uploaded_file($_FILES["fupload1"]["tmp_name"], $vfile_upload); $ext= end(explode('.', $_FILES['fupload1']['name'])); //identitas file asli //untuk membuat ukuran small if($ext=="jpg" || $ext=="jpeg" ) { $im_src = imagecreatefromjpeg($vfile_upload); } else if($ext=="png") { $im_src = imagecreatefrompng($vfile_upload); } else if($ext=="gif") { $im_src = imagecreatefromgif($vfile_upload); } else { $im_src = imagecreatefrombmp($vfile_upload); } $src_width = imageSX($im_src); $src_height = imageSY($im_src); //Simpan dalam versi small 200 pixel //Set ukuran gambar hasil perubahan $dst_width =200; $dst_height = ($dst_width/$src_width)*$src_height; $im = imagecreatetruecolor($dst_width,$dst_height); imagecopyresampled($im, $im_src, 0, 0, 0, 0, $dst_width, $dst_height, $src_width, $src_height); $dst_width2 =50; $dst_height2 = ($dst_width2/$src_width)*$src_height; //proses perubahan ukuran $im2 = imagecreatetruecolor($dst_width2,$dst_height2); imagecopyresampled($im2, $im_src, 0, 0, 0, 0, $dst_width2, $dst_height2, $src_width, $src_height); //Simpan gambar imagejpeg($im,$vdir_upload . "medium_" . $fupload_name); imagejpeg($im2,$vdir_upload . "small_" . $fupload_name); //Hapus gambar di memori komputer imagedestroy($im_src); imagedestroy($im); imagedestroy($im2); } function UploadCustomer2($fupload_name){ //direktori gambar $vdir_upload = "../../../images/customer/"; $vfile_upload = $vdir_upload . $fupload_name; //Simpan gambar dalam ukuran sebenarnya move_uploaded_file($_FILES["fupload2"]["tmp_name"], $vfile_upload); $ext= end(explode('.', $_FILES['fupload2']['name'])); //identitas file asli //untuk membuat ukuran small if($ext=="jpg" || $ext=="jpeg" ) { $im_src = imagecreatefromjpeg($vfile_upload); } else if($ext=="png") { $im_src = imagecreatefrompng($vfile_upload); } else if($ext=="gif") { $im_src = imagecreatefromgif($vfile_upload); } else { $im_src = imagecreatefrombmp($vfile_upload); } $src_width = imageSX($im_src); $src_height = imageSY($im_src); //Simpan dalam versi small 200 pixel //Set ukuran gambar hasil perubahan $dst_width =200; $dst_height = ($dst_width/$src_width)*$src_height; $im = imagecreatetruecolor($dst_width,$dst_height); imagecopyresampled($im, $im_src, 0, 0, 0, 0, $dst_width, $dst_height, $src_width, $src_height); $dst_width2 =50; $dst_height2 = ($dst_width2/$src_width)*$src_height; //proses perubahan ukuran $im2 = imagecreatetruecolor($dst_width2,$dst_height2); imagecopyresampled($im2, $im_src, 0, 0, 0, 0, $dst_width2, $dst_height2, $src_width, $src_height); //Simpan gambar imagejpeg($im,$vdir_upload . "medium_" . $fupload_name); imagejpeg($im2,$vdir_upload . "small_" . $fupload_name); //Hapus gambar di memori komputer imagedestroy($im_src); imagedestroy($im); imagedestroy($im2); } function UploadCustomer3($fupload_name){ //direktori gambar $vdir_upload = "../../../images/customer/"; $vfile_upload = $vdir_upload . $fupload_name; //Simpan gambar dalam ukuran sebenarnya move_uploaded_file($_FILES["fupload3"]["tmp_name"], $vfile_upload); $ext= end(explode('.', $_FILES['fupload3']['name'])); //identitas file asli //untuk membuat ukuran small if($ext=="jpg" || $ext=="jpeg" ) { $im_src = imagecreatefromjpeg($vfile_upload); } else if($ext=="png") { $im_src = imagecreatefrompng($vfile_upload); } else if($ext=="gif") { $im_src = imagecreatefromgif($vfile_upload); } else { $im_src = imagecreatefrombmp($vfile_upload); } $src_width = imageSX($im_src); $src_height = imageSY($im_src); //Simpan dalam versi small 200 pixel //Set ukuran gambar hasil perubahan $dst_width =200; $dst_height = ($dst_width/$src_width)*$src_height; $im = imagecreatetruecolor($dst_width,$dst_height); imagecopyresampled($im, $im_src, 0, 0, 0, 0, $dst_width, $dst_height, $src_width, $src_height); $dst_width2 =50; $dst_height2 = ($dst_width2/$src_width)*$src_height; //proses perubahan ukuran $im2 = imagecreatetruecolor($dst_width2,$dst_height2); imagecopyresampled($im2, $im_src, 0, 0, 0, 0, $dst_width2, $dst_height2, $src_width, $src_height); //Simpan gambar imagejpeg($im,$vdir_upload . "medium_" . $fupload_name); imagejpeg($im2,$vdir_upload . "small_" . $fupload_name); //Hapus gambar di memori komputer imagedestroy($im_src); imagedestroy($im); imagedestroy($im2); } function UploadOutlet1($fupload_name){ //direktori gambar $vdir_upload = "../../../images/outlet/"; $vfile_upload = $vdir_upload . $fupload_name; //Simpan gambar dalam ukuran sebenarnya move_uploaded_file($_FILES["fupload1"]["tmp_name"], $vfile_upload); $ext= end(explode('.', $_FILES['fupload1']['name'])); //identitas file asli //untuk membuat ukuran small if($ext=="jpg" || $ext=="jpeg" ) { $im_src = imagecreatefromjpeg($vfile_upload); } else if($ext=="png") { $im_src = imagecreatefrompng($vfile_upload); } else if($ext=="gif") { $im_src = imagecreatefromgif($vfile_upload); } else { $im_src = imagecreatefrombmp($vfile_upload); } $src_width = imageSX($im_src); $src_height = imageSY($im_src); //Simpan dalam versi small 200 pixel //Set ukuran gambar hasil perubahan $dst_width =200; $dst_height = ($dst_width/$src_width)*$src_height; $im = imagecreatetruecolor($dst_width,$dst_height); imagecopyresampled($im, $im_src, 0, 0, 0, 0, $dst_width, $dst_height, $src_width, $src_height); $dst_width2 =50; $dst_height2 = ($dst_width2/$src_width)*$src_height; //proses perubahan ukuran $im2 = imagecreatetruecolor($dst_width2,$dst_height2); imagecopyresampled($im2, $im_src, 0, 0, 0, 0, $dst_width2, $dst_height2, $src_width, $src_height); //Simpan gambar imagejpeg($im,$vdir_upload . "medium_" . $fupload_name); imagejpeg($im2,$vdir_upload . "small_" . $fupload_name); //Hapus gambar di memori komputer imagedestroy($im_src); imagedestroy($im); imagedestroy($im2); } function UploadOutlet2($fupload_name){ //direktori gambar $vdir_upload = "../../../images/outlet/"; $vfile_upload = $vdir_upload . $fupload_name; //Simpan gambar dalam ukuran sebenarnya move_uploaded_file($_FILES["fupload2"]["tmp_name"], $vfile_upload); $ext= end(explode('.', $_FILES['fupload2']['name'])); //identitas file asli //untuk membuat ukuran small if($ext=="jpg" || $ext=="jpeg" ) { $im_src = imagecreatefromjpeg($vfile_upload); } else if($ext=="png") { $im_src = imagecreatefrompng($vfile_upload); } else if($ext=="gif") { $im_src = imagecreatefromgif($vfile_upload); } else { $im_src = imagecreatefrombmp($vfile_upload); } $src_width = imageSX($im_src); $src_height = imageSY($im_src); //Simpan dalam versi small 200 pixel //Set ukuran gambar hasil perubahan $dst_width =200; $dst_height = ($dst_width/$src_width)*$src_height; $im = imagecreatetruecolor($dst_width,$dst_height); imagecopyresampled($im, $im_src, 0, 0, 0, 0, $dst_width, $dst_height, $src_width, $src_height); $dst_width2 =50; $dst_height2 = ($dst_width2/$src_width)*$src_height; //proses perubahan ukuran $im2 = imagecreatetruecolor($dst_width2,$dst_height2); imagecopyresampled($im2, $im_src, 0, 0, 0, 0, $dst_width2, $dst_height2, $src_width, $src_height); //Simpan gambar imagejpeg($im,$vdir_upload . "medium_" . $fupload_name); imagejpeg($im2,$vdir_upload . "small_" . $fupload_name); //Hapus gambar di memori komputer imagedestroy($im_src); imagedestroy($im); imagedestroy($im2); } function UploadOutlet3($fupload_name){ //direktori gambar $vdir_upload = "../../../images/outlet/"; $vfile_upload = $vdir_upload . $fupload_name; //Simpan gambar dalam ukuran sebenarnya move_uploaded_file($_FILES["fupload3"]["tmp_name"], $vfile_upload); $ext= end(explode('.', $_FILES['fupload3']['name'])); //identitas file asli //untuk membuat ukuran small if($ext=="jpg" || $ext=="jpeg" ) { $im_src = imagecreatefromjpeg($vfile_upload); } else if($ext=="png") { $im_src = imagecreatefrompng($vfile_upload); } else if($ext=="gif") { $im_src = imagecreatefromgif($vfile_upload); } else { $im_src = imagecreatefrombmp($vfile_upload); } $src_width = imageSX($im_src); $src_height = imageSY($im_src); //Simpan dalam versi small 200 pixel //Set ukuran gambar hasil perubahan $dst_width =200; $dst_height = ($dst_width/$src_width)*$src_height; $im = imagecreatetruecolor($dst_width,$dst_height); imagecopyresampled($im, $im_src, 0, 0, 0, 0, $dst_width, $dst_height, $src_width, $src_height); $dst_width2 =50; $dst_height2 = ($dst_width2/$src_width)*$src_height; //proses perubahan ukuran $im2 = imagecreatetruecolor($dst_width2,$dst_height2); imagecopyresampled($im2, $im_src, 0, 0, 0, 0, $dst_width2, $dst_height2, $src_width, $src_height); //Simpan gambar imagejpeg($im,$vdir_upload . "medium_" . $fupload_name); imagejpeg($im2,$vdir_upload . "small_" . $fupload_name); //Hapus gambar di memori komputer imagedestroy($im_src); imagedestroy($im); imagedestroy($im2); } ?>y~or5J={Eeu磝Qk ᯘG{?+]ן?wM3X^歌>{7پK>on\jy Rg/=fOroNVv~Y+ NGuÝHWyw[eQʨSb> >}Gmx[o[<{Ϯ_qFvM IENDB`