This version last updated 11 August 2006
Snippet name: EtoGal
Author: hugelmopf (+ mikef)
Version: 1.1 (Beta)
- Minimum Etomite version: 0.6.1 (while RC1 and later will work, Final is of course preferred. These instructions relate to RC3 and upwards.)
- User login snippet: A user login snippet is required for access to the management functions.
There are currently two possible snippets to use.Ralph's EtomiteLoginOut snippet, which is compatible with RC3 and up- no longer available- Ralph's Authenticate_visitor snippet from the snippet library, which has more functionality and is preferred, but is only compatible with 0.6.1Final
- You should have Etomite access permissions enabled, because that is what EtoGal's admin mode is based on! (if you don't, only administrators will be able to manage the galleries)
This gallery was made for Etomite and is very deeply integrated (database, access permissions etc.). It is very flexible in integrating in your site and you will be able to integrate a new gallery into every page of your site you like.
Despite the flexibility, installation remains simple.
There is a demo of the frontend for EtoGal at the Demo URL, but there isn't a current demonstration for the admin (one may be added some time after Etomite 0.6.1 final is released). Other examples of EtoGal's use can be found in the 'Showcase' section.
- Picture-Upload (up to 10 at a time, jpegs or zips) and thumbnail creation with GD
- Complete control over access rights (uses Etomite's access rights for every page you place a gallery on)
- easily and all at once edit pictures descriptions/delete pictures
- different modes for displaying the full size pictures (including pop-up, different page with e.g. a different template)
- navigation in picture view (thanks to bastian29)
- easy switching between admin-mode and view-mode
- different options for order of pictures, including (EXIF/edit) date, title, filename, upload date. (as snippetcall parameters)
- mode for listing all galleries that exist in children pages (with thumbs, title and link)
You have to have Etomite access permissions enabled, because that is what EtoGal's admin mode is based on!
- Download the latest Etogal.php file from the Etogal download area and add it to your installation as a snippet: go to Etomite manager -> Manage Resources -> Manage Snippets -> New snippet -> "Name: EtoGal" and paste the complete text from the file into the Snippet code field.
- Download a login snippet (Authenticate_visitor preferred), and add it to your installation as a snippet.
- Create a folder (e.g. assets/galleries) where you want your pictures stored and make it writeable for the webserver. If needed, change the $path_to_galleries variable in the beginning of the EtoGal Snippet code appropriately.
- Add a gallery to any of your pages by adding a call to the Etogl snippet (ie adding [[EtoGal]] or [!EtoGal!] to the page content). This page will need to be published for normal use - remember the page id.
A folder with the name of the page ID will be created automatically in $path_to_galleries, and all pictures/thumbnails for this page's gallery will be uploaded/created in this folder. Database creation and everything else is taken care of automatically. - Add a page to allow users to login. If you are only using the login for a single EtoGal gallery you might want to make the login snippet automatically redirect to the page with the Gallery (pass the id to the snippet as a parameter (eg [[EtomiteLoginOut?id=id]])). This page will need to be published, but need not be part of the site menu structure. (you could combine the login and etogal snippets on a single page for initial testing)
- Go to the login page you created as a user and login (using credentials defined in the manager for manager logins). Note that EtoGal respects the rights defined in the manager, so you must have access rights for the page. Initially its easier to use the admin login for testing.
- display=[embedded | childgalleries|none]
Three special modes:
embedded: Makes full size pictures pop up in a new window without any HTML around them.
childgalleries: Will produce an overview of galleries in the children pages.
none: beta 2 and later only displays when in admin mode (for use with the associated etoGalGallery snippet for even more flexibility in display, nd eaasier customisation).
Default: not chosen - picture_target=NUMBER
Full size pictures can be displayed on a different page (possibly with a different template/text around it), whose ID you can specify here. You just have to place an [[EtoGal?is_target=yes]] call on that page. (overwrites display=embedded)
If nothing is specified, it uses the same page as the gallery is on.
Default: not chosen - titles_in_overview=[no | yes]
Shall picture titles be shown in the picture overview, or only on the picture view page? Useful for embedded mode, because no titles are shown in the "pure picture" pop up window
Default: no - max_pic_size=NUMBER
If this is nonzero, larger pictures will get resized on uploading.
Default: 800 - max_thumb_size=NUMBER
Thumbnails will get created with the longer edge this size.
Default: 150 - pics_in_a_row=NUMBER
Pretty self-explanatory... number of pictures in a row in the overview
Default: 3 - order_by=[date | id | filename | title]
In the picture overview, pictures are ordered by: EXIF/last edit date, picture id ("upload date"), filename or title.
Default: date - order_direction=[ASC | DESC]
together with the order_by parameter, this determines which direction the order should take: ascending or descending.
Default: DESC (together with date brings newest pictures on top) - keep_date=[yes | no]
If yes, then EtoGal won't reset the date on each picture when editing. This means, the date will be left at the upload status (which is either the upload date or the EXIF date).
Default: no - gtable=TEXT
This allows you to rename the name of the table that gets created in your database (should not be necessary except for testing purposes).
Default: etogal - quality=[low|medium|high] (only with beta 2 or higher)
This selects tradeoffs between upload processing time and image file size against final image quality for thumbnails and larger image if it is resized to the maximum on loading.
low: quick to load, small file, but uses a fast resizing algorithm, and agressive jpeg compression
medium: slower to load (using a better resizing algorithm), and agressive jpeg compression
high: slower to load, and less agressive compression
Default: low (to match etoGal 1.0, but may be changed later) - delete=[0|1] (only with beta 2 or higher)
If delete is set to zero, users who have edit rights to the gallery page will be able to add images and edit their titles and descriptions, but will not be able to delete images. Only administrators will be able to delete images.
Default: 1
- you can only have one instance of EtoGal on each page
Use when PHP is installed to operate in 'Safe Mode'
Safe mode causes file access permission problems for EtoGal. When new galleries are created, it's impossible to put images into them. The following instructions come from martin.kuna
Quote
1) make new document in etomite (for example with id 10), insert the snippet [ [etogal]]
2) create new directory in ftp client with the same name as id of my document (in this case 10)
3) set chmod 777 for this directory in ftp client
4) upload new images using etogal snippet
Hugelmopf posted a version for use with Etomite 0.6 at this post later in the original Etogal support thread: http://www.etomite.com/index.php?sh...ost&p=19794
This one will not be updated though, and is incompatible with add-on snippets.
(edit - removed EtomiteLoginOut from list of login snippets as no longer availble)
Edited by mikef, 17 June 2007 - 09:48 AM.












