App::501::functions

DESCRIPTION


DEPENDS

FUNCTIONS

image_regenerate()

image_regenerate
(
  'image.ID_entity' => '' # related image.ID_entity
  'image.ID' => '' # related image.ID
)

image_file_generate()

image_file_generate
(
  'image.ID' => '' # related image.ID
  'image.ID_entity' => '' # related image.ID_entity
  'image_format.ID' => '' # related image_format.ID
  #'image_format.name' => '' # realted image_format.name
)

image_add()

Adds new image to gallery, or updates old image

Add new image (uploading new original sized image)

 image_add
 (
   'file' => '/path/to/file',
   'image.ID' => '',
   'image.ID_entity' => '',
   'image_format.ID' => '',
#   'image_attrs.ID_category' => '',
#   'image_attrs.name' => '',
#   'image_attrs.description' => '',
 );

image_del()

Remove image from gallery

image_file_add()

Adds new file to image, or updates old

$image_file{'ID'}=image_file_add
(
  'file' => '/path/to/file',
  'image.ID_entity' => '',
  'image_format.ID' => ''
)

image_file_rewrite()

Rewrite file with new content, or just update datetime_create when content of new file is the same as old

image_file_rewrite
(
       file => '/path/to/file'
       columns => # columns to change
       {
               'status' => 'Y'
       }
)

image_file_newhash()

Find new unique hash for file

get_image_file()

Return image_file columns. This is the fastest way (optimized SQL) to get informations about file in image. Informations are cached in memcached and cache is monitored by information of last change of a501_image.

my %image_file=get_image_file(
        'image.ID_entity' => 1 or 'image.ID' = > 1
        'image_file.ID_format' => 1 # default
        'image_attrs.lng' => $tom::lng # default
        ''
)

AUTHORS

Comsultia, Ltd. (open@comsultia.com)


If published informations are not helpfull, something is missing or wrong, please report. Thanx for contribution.
This content is generated from file 'http://svn.cyclone3.org/trunk/frame/_addons/App/501/functions.pm'

AddThis Social Bookmark Button RSS

User Comments