Changeset 1615
- Timestamp:
- 07/06/08 20:50:47 (5 months ago)
- Location:
- trunk
- Files:
-
- 4 modified
-
docs/CHANGELOG (modified) (1 diff)
-
lib/class/core.class.php (modified) (1 diff)
-
lib/class/vainfo.class.php (modified) (1 diff)
-
templates/show_album_art.inc.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/docs/CHANGELOG
r1608 r1615 5 5 -------------------------------------------------------------------------- 6 6 v.3.5-Alpha1 7 - Added Image Dimensions on Find Album Art page 7 8 - Added Confirmation Screen to Catalog Deletion 8 9 - Reorganized Menu System and Added Modules section -
trunk/lib/class/core.class.php
r1608 r1615 88 88 } // form_verify 89 89 90 /** 91 * image_dimensions 92 * This returns the dimensions of the passed song of the passed type 93 * returns an empty array if PHP-GD is not currently installed, returns 94 * false on error 95 */ 96 public static function image_dimensions($image_data) { 97 98 if (!function_exists('ImageCreateFromString')) { return false; } 99 100 $image = ImageCreateFromString($image_data); 101 102 if (!$image) { return false; } 103 104 $width = imagesx($image); 105 $height = imagesy($image); 106 107 if (!$width || !$height) { return false; } 108 109 return array('width'=>$width,'heigh'=>$height); 110 111 } // image_dimensions 112 90 113 } // Core 91 114 ?> -
trunk/lib/class/vainfo.class.php
r1569 r1615 495 495 private function _clean_tag($tag,$encoding='') { 496 496 497 return $tag; 498 497 499 // If we've got iconv then go ahead and clear her up 498 500 if ($this->_iconv) { -
trunk/templates/show_album_art.inc.php
r1518 r1615 34 34 $key = $i*4+$j; 35 35 $image_url = Config::get('web_path') . '/image.php?type=session&image_index=' . $key; 36 $dimensions = Core::image_dimensions(get_image_from_source($_SESSION['form']['images'][$key])); 36 37 if (!isset($images[$key])) { echo "<td> </td>\n"; } 37 38 else { 38 39 ?> 39 40 <td align="center"> 40 <a href="<?php echo $image_url; ?>" target="_blank"> 41 <img src="<?php echo $image_url; ?>" alt="Album Art" border="0" height="175" width="175" /><br /> 42 </a> 41 <a href="<?php echo $image_url; ?>" target="_blank"><img src="<?php echo $image_url; ?>" alt="Album Art" border="0" height="175" width="175" /></a> 42 <br /> 43 43 <p align="center"> 44 [<a href="<?php echo Config::get('web_path'); ?>/albums.php?action=select_art&image=<?php echo $key; ?>&album_id=<?php echo urlencode($_REQUEST['album_id']); ?>">Select</a>] 44 <?php if (is_array($dimensions)) { ?> 45 [<?php echo intval($dimensions['width']); ?>x<?php echo intval($dimensions['heigh']); ?>] 46 <?php } ?> 47 [<a href="<?php echo Config::get('web_path'); ?>/albums.php?action=select_art&image=<?php echo $key; ?>&album_id=<?php echo intval($_REQUEST['album_id']); ?>">Select</a>] 45 48 </p> 46 49 </td>
