- Timestamp:
- 2006/11/27 13:15:03 (20 years ago)
- File:
-
- 1 edited
-
temp/trunk/html/admin/products/product.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
temp/trunk/html/admin/products/product.php
r9129 r9130 501 501 $src_w = 0; 502 502 $src_h = 0; 503 504 sfprintr($objUpFile); 503 505 504 506 switch ($_POST['image_key']){ … … 540 542 } 541 543 544 // ½Ì¾®²èÁüÀ¸À® 545 function lfMakeScaleImage($from_key, $to_key){ 546 global $objUpFile; 547 global $arrImageKey; 548 549 // ¸µ²èÁü¥µ¥¤¥º¤ò¼èÆÀ 550 $src_path = $objUpFile->temp_dir . $objUpFile->temp_file[$arrImageKey[$from_key]]; 551 list($src_w, $src_h) = getimagesize($src_path); 552 553 if($objUpFile->temp_file[$arrImageKey[$to_key] == ""){ 554 // ¸µ²èÁü¤Î¤Û¤¦¤¬Â礤¤¾ì¹ç¤Ë¤Ï½Ì¾®Î¨ÀßÄê 555 if(NORMAL_IMAGE_WIDTH < $src_w and NORMAL_IMAGE_HEIGHT < $src_h){ 556 ($src_w > $src_h) ? $scale = NORMAL_IMAGE_WIDTH / $src_w : $scale = NORMAL_IMAGE_HEIGHT / $src_h; 557 }else{ 558 $scale = 1; 559 } 560 $path = $objUpFile->saveResizeImage($_POST['image_key'], $scale); 561 $objUpFile->temp_file[$arrImageKey[$to_key] = $path; 562 } 563 } 564 542 565 ?>
Note: See TracChangeset
for help on using the changeset viewer.
