Loading...
 

File Gallery Handler

This is a handler that allows file galleries to created or updated. Object References are required to create trees of file galleries. Uploading files is not supported before Tiki 9 when the init_files option was introduced.

Complete sample for an Intranet

YAML
preferences:
 feature_file_galleries: y
objects:
 -
  type: file_gallery
  ref: primary
  data:
   name: Company XYZ
   description: All files owned by the company
   owner: admin
   archives: 5
   flags: [ public, visible, lockable ]
   column: [ icon, name, created, creator, files ]
   init_files:
    - https://profiles.tiki.org/pics/icons/plugin.png
 -
  type: file_gallery
  ref: public
  data:
   name: Marketing
   parent: $primary
   description: For external publication
   owner: johndoe
   flags: [ public ]
   column: [ icon, name, files ]
   popup: [ description ]


File Gallery Object


All the items in the table below are parameters that are set at the 'data' level of the YAML and are generally applicable for Tiki12 and later but may not all work for earlier Tiki versions.

Before the data level, ie at the first 'object' level the type: is defined i.e. file_gallery, a ref: can be defined.

TO VERIFY: previously documented "In addition a mode option can be set which can be 'create' or 'update' or 'create_update' (default: create even if exists)." It should be that the mode be set at the "data" level not at the higher level. But it seems like it depends on whether galleryId is set or not. If galleryId is not set, then it always creates a new one (and update mode will generate an error). If update mode is set, then it checks that the file gallery specified exists. Other than this checking, it looks like the mode has no effect. If mode is not set, it will update if galleryId is set or create a new one if galleryId is not set


Field NameMandatoryValue
nameyesName of the file gallery
parent Parent file gallery ID
description Description of the file gallery
owner User maintaining the file gallery, default to admin
type default, podcast or vidcast
maxRows Amount of rows to display at a time
max_desc Description length in characters
archives Amount of archives to keep per file. 0 for unlimited, default to none (-1)
sort_mode Default sort order ie Name Ascending or Descending is set by using either name_asc or name_desc - other sort types set by using lastModif_ hits_ user_ description_ or id_
subgal_conf
image_max_size_x Maximum width in pixels of images in gallery
image_max_size_y Maximum height in pixels of images in gallery
quota Quota for the allowed storage limit for the File Gallery in Mb
backlinkPerms
wiki_syntax
icon_fileId Gallery Icon fileId#
flags List of global flags
publicFile gallery is unlocked (public)
visibleVisible to non-admins
lockableFiles can be locked during download
show_name name, filename or both (default: both)
init_files URL to file to add to this file gallery (New in Tiki9)
column or popup List of elements to display publicly
label used in 'Display Properties' admin screen parameter to be used in profile script
IDid
Typeicon
Descriptiondescription
Sizesize
Created / Uploadedcreated
Last Modifiedmodified
Uploaded by creator (not obvious!!)
Creatorauthor (not obvious!!)
Last Modified by last_user
Commentcomment
Filesfiles
Hitshits
Last downloadlastDownload
Locked bylockedby
Backlinksbacklinks
Delete AfterdeleteAfter
Share withshare
Sourcesource
Explorerexplorer
Pathpath


Category: Documentation