Class Mage_XmlConnect_Helper_Image

Description

Magento

NOTICE OF LICENSE

This source file is subject to the Open Software License (OSL 3.0) that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://opensource.org/licenses/osl-3.0.php If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to [email protected] so we can send you a copy immediately.

DISCLAIMER

Do not edit or add to this file if you wish to upgrade Magento to newer versions in the future. If you wish to customize Magento for your needs please refer to http://www.magentocommerce.com for more information.

Located in /XmlConnect/Helper/Image.php (line 27)

Mage_Core_Helper_Abstract
   |
   --Mage_XmlConnect_Helper_Image
Class Constant Summary
Variable Summary
array|null $_confPaths
array|null $_content
array|null $_interface
Method Summary
string filterScreenSize (string $screenSize)
&mixed &findPath ( &$array, string $path, array $array)
string|null getCustomSizeImageUrl ( $imageUrl, [int $width = 100], [ $height = 100])
string getCustomSizeUploadDir (string $screenSize)
string getFileCustomDirSuffixAsUrl (string $confPath, string $fileName)
string getFileDefaultSizeSuffixAsUrl (string $fileName)
array getImageLimits ([string $screenSize = Mage_XmlConnect_Model_Application::APP_SCREEN_SIZE_DEFAULT])
int getImageSizeForContent (string $imageName)
int getImageSizeForInterface (string $imagePath)
array|string getInterfaceImagesPaths ([string $imagePath = null])
string getOldUploadDir ()
string getSkinImagesUrl ([string $name = null])
void handleUpload (string $field, mixed &$target)
void _forcedConvertPng (string $field)
string _getResizedFilename (string $fieldPath, string $fileName, [string $default = false])
string _getScreenSize ()
void _handleResize (string $fieldPath, string $file)
void _verifyDirExist (string $dir)
void _zoom ( &$item, mixed $key, string $value, mixed $item)
Variables
array|null $_confPaths = null (line 64)

Images paths in the config

  • access: protected
array|null $_content = null (line 36)

Image limits for content

  • access: protected
array $_imageLimits = array() (line 57)

Image limits array

  • access: protected
array|null $_interface = null (line 43)

Image limits for interface

  • access: protected
array $_interfacePath = array() (line 50)

Array of interface image paths in xmlConfig

  • access: protected

Inherited Variables

Inherited from Mage_Core_Helper_Abstract

Mage_Core_Helper_Abstract::$_layout
Mage_Core_Helper_Abstract::$_moduleName
Mage_Core_Helper_Abstract::$_request
Methods
filterScreenSize (line 391)

Ensure correct $screenSize value

  • access: public
string filterScreenSize (string $screenSize)
  • string $screenSize
findPath (line 525)

Return reference to the $path in $array

  • return: //(reference)
  • access: public
&mixed &findPath ( &$array, string $path, array $array)
  • array $array
  • string $path
  • &$array
getCustomSizeDirPrefix (line 255)

Return CustomSizeDirPrefix

  • access: public
string getCustomSizeDirPrefix ()
getCustomSizeImageUrl (line 349)

Retrieve thumbnail image url

  • access: public
string|null getCustomSizeImageUrl ( $imageUrl, [int $width = 100], [ $height = 100])
  • int $width
  • $imageUrl
  • $height
getCustomSizeUploadDir (line 575)

Return customSizeUploadDir path

  • access: public
string getCustomSizeUploadDir (string $screenSize)
  • string $screenSize
getDefaultSizeUploadDir (line 614)

Return default size upload dir path

  • access: public
string getDefaultSizeUploadDir ()
getFileCustomDirSuffixAsUrl (line 278)

Return getFileCustomDirSuffixAsUrl

  • access: public
string getFileCustomDirSuffixAsUrl (string $confPath, string $fileName)
  • string $confPath
  • string $fileName
getFileDefaultSizeSuffixAsUrl (line 266)

Return FileDefaultSizeSuffixAsUrl

  • access: public
string getFileDefaultSizeSuffixAsUrl (string $fileName)
  • string $fileName
getImageLimits (line 428)

Return correct size array for given device screen_size(320x480/640x960_a)

  • access: public
array getImageLimits ([string $screenSize = Mage_XmlConnect_Model_Application::APP_SCREEN_SIZE_DEFAULT])
  • string $screenSize
getImageSizeForContent (line 289)

Return correct size for given $imageName and device screen_size

  • access: public
int getImageSizeForContent (string $imageName)
  • string $imageName
getImageSizeForInterface (line 326)

Return correct size for given $imageName and device screen_size

  • access: public
int getImageSizeForInterface (string $imagePath)
  • string $imagePath
getInterfaceImageLimits (line 311)

Return setting for interface images (image size limits)

  • access: public
array getInterfaceImageLimits ()
getInterfaceImagesPaths (line 644)

Return 1) default interface image path for specified $imagePath 2) array of image paths

  • access: public
array|string getInterfaceImagesPaths ([string $imagePath = null])
  • string $imagePath
getInterfaceImagesPathsConf (line 624)

Return array for interface images paths in the config

  • access: public
array getInterfaceImagesPathsConf ()
getOldUploadDir (line 602)

Return oldUpload dir path (media/xmlconnect)

  • access: public
string getOldUploadDir ()
getOriginalSizeUploadDir (line 590)

Return originalSizeUploadDir path

  • access: public
string getOriginalSizeUploadDir ()
getSkinImagesUrl (line 245)

Retrieve xmlconnect images skin url

  • access: public
string getSkinImagesUrl ([string $name = null])
  • string $name
handleUpload (line 73)

Process uploaded file setup filenames to the configuration

  • access: public
void handleUpload (string $field, mixed &$target)
  • string $field
  • mixed &$target
_forcedConvertPng (line 214)

Convert uploaded file to PNG

  • access: protected
void _forcedConvertPng (string $field)
  • string $field
_getResizedFilename (line 119)

Return correct system filename for current screenSize

  • access: protected
string _getResizedFilename (string $fieldPath, string $fileName, [string $default = false])
  • string $fieldPath
  • string $fileName
  • string $default
_getScreenSize (line 106)

Return current screen_size parameter

  • access: protected
string _getScreenSize ()
_handleResize (line 165)

Resize uploaded file

  • access: protected
void _handleResize (string $fieldPath, string $file)
  • string $fieldPath
  • string $file
_verifyDirExist (line 563)

Ensure $dir exists (if not then create one)

  • access: protected
void _verifyDirExist (string $dir)
  • string $dir
_zoom (line 550)

Multiply given $item by $value if non array

  • access: protected
void _zoom ( &$item, mixed $key, string $value, mixed $item)
  • mixed $item: (argument to change)
  • mixed $key: (not used)
  • string $value: (contains float)
  • &$item

Inherited Methods

Inherited From Mage_Core_Helper_Abstract

Mage_Core_Helper_Abstract::escapeHtml()
Mage_Core_Helper_Abstract::escapeUrl()
Mage_Core_Helper_Abstract::getLayout()
Mage_Core_Helper_Abstract::htmlEscape()
Mage_Core_Helper_Abstract::isModuleEnabled()
Mage_Core_Helper_Abstract::isModuleOutputEnabled()
Mage_Core_Helper_Abstract::jsQuoteEscape()
Mage_Core_Helper_Abstract::setLayout()
Mage_Core_Helper_Abstract::stripTags()
Mage_Core_Helper_Abstract::translateArray()
Mage_Core_Helper_Abstract::urlDecode()
Mage_Core_Helper_Abstract::urlEncode()
Mage_Core_Helper_Abstract::urlEscape()
Mage_Core_Helper_Abstract::_cleanCache()
Mage_Core_Helper_Abstract::_getModuleName()
Mage_Core_Helper_Abstract::_getRequest()
Mage_Core_Helper_Abstract::_getUrl()
Mage_Core_Helper_Abstract::_loadCache()
Mage_Core_Helper_Abstract::_removeCache()
Mage_Core_Helper_Abstract::_saveCache()
Mage_Core_Helper_Abstract::__()
Class Constants
XMLCONNECT_GLUE = '_' (line 29)

Documentation generated on Fri, 11 Feb 2011 17:06:22 +0200 by phpDocumentor 1.4.3