DEPRECATION WARNING

This documentation is not using the current rendering mechanism and is probably outdated. The extension maintainer should switch to the new system. Details on how to use the rendering mechanism can be found here.

EXT: Photographic Library

Author:Kasper Skårhøj
Created:2002-11-01T00:32:00
Changed by:Mathieu Vidal
Changed:2007-09-27T17:11:09
Email:mathaaus.typo3@gmail.com

EXT: Photographic Library

Extension Key: photographic_library

Copyright 2000-2002, mathaaus.typo3@gmail.com, <mathaaus.typo3@gmail.com>

This document is published under the Open Content License

available from http://www.opencontent.org/opl.shtml

The content of this document is related to TYPO3

- a GNU/GPL CMS/Framework available from www.typo3.com

Table of Contents

EXT: Photographic Library 1

Introduction 1

What does it do? 1

Screenshots 1

Users manual 3

How to install the extension 3

Codes description : 3

Remarks : 3

How to manage photos items and albums objects 4

Configuration 5

Adminstration 5

Known problems 5

To-Do list 5

Changelog 5

Introduction

What does it do?

The Photographic Library can be used to place a list of photo on a website with a link to enlarge it. This list can be all the photographics of a system folder or only some of it groups on an album or only some of it groups on a topic.

There is a search engine too. It allow to look for photographics by keyword on title, description or keywords and/or by a topic associated to photographics and/or in an album.

To add photographic you have got two method :

  • create new record on backend allow to add one photographic with specific information,
  • Add a zip file with several photographic allow to add several photographic with the same information.

Screenshots

You can see sreenshots for :

  • Code LIST, RANDOM and SEARCH : here
  • Code SINGLE : here

Users manual

How to install the extension

Create a sysfolder for the topics, the photographics, and the albums,

Create a page for the plugin with code LIST,

Create a page for the plugin with code SINGLE, for this one you must add a new template, if you want a popup without your site template. This method is only if you use the display on a popup (see constant editor). The simplest is to add template with the following script :

page = PAGE

page.typeNum = 0

page.10 < styles.content.get

Don't forget to add “content(default)” on “Include static” section.

Create a page for the plugin with code SEARCH,

Create a page for the plugin with code ALBUM,

Create a page for the plugin with code TOPICLIST,

Create a page for the plugin with code ALBUMLIST,

Create a page for the plugin with code RANDOM,

For each of these pages, add the photographic library plugin with the right code selected on listbox “Type of display”

img-1 Illustration 1Look for this picture to add extension with wizard for a new content element

img-2 The sysfolder which contain your photographic has to be set as Startingpoint for the code LIST and SEARCH and possibly for the code ALBUM.

The field “Topic id (for LIST) or Album id (for ALBUM) allow to select a specific topic or a specific album to display it

The field layout allow to choose between 4 presentations for ALBUM, LIST or SINGLE

Codes description :

ALBUM

CODE

ALBUM

Use CE

Template file, "Single" pid, Maximum size, Number of photos, Enlarging link

Description

Display the name of album(s) and the photos of album(s) on the page. If there is a startingpoint, use album(s) on it, else use album(s) on current page.

Startingpoint

YES or NO

LIST

CODE

LIST

Use CE

Template file, "Single" pid, Maximum size, Number of photos, Enlarging link

Description

Display the list of all the photos of a startingpoint with a link on each to see the detail.

Startingpoint

YES

SINGLE

CODE

SINGLE

Use CE

Template file, Maximum single size, Single title backgroundcolor, Default copyright, Horizontal margin, Vertical margin, Pop-up width, Pop-up height

Description

Display the detail of a photo in a popup window .

Startingpoint

NO

TOPICLIST

CODE

TOPICLIST

Use CE

Template file, "List" pid, Topic name wrap

Description

Display the list of all photo topics which are not hidden or deleted with a link to the LIST page to show all the photos of a selected topic.

Startingpoint

YES

ALBUMLIST

CODE

ALBUMLIST

Use CE

Template file, "List" pid, Album name wrap

Description

Display the list of all albums which are not hidden or deleted with a link to the LIST pages to show all the photos of a selected album.

Startingpoint

YES

RANDOM

CODE

RANDOM

Use CE

Number of line,Number of column

Description

Display a table of random image with no link to see the enlarge photographic

Startingpoint

YES

Remarks :
  • The default code is the code LIST,
  • Page with ALBUM, TOPICLIST or ALBUMLIST code diplays all albums or topic of the current page (if no starting point) or albums or topic of the starting point,
  • Layouts allow different page-setting and different displayed fields, see on template to change them,
  • Pages recursivity is dealt with,
  • In an album, photographs are displayed in order they were selected,
  • The field “Topic id (for LIST) or Album id (for ALBUM)” associated with code LIST allow to display photographs for a specific topic,
  • The field “Topic id (for LIST) or Album id (for ALBUM)” associated with code ALBUM allow to display photographs for a specific album.

How to manage photos items and albums objects

The records of the photographic library (topics and photographs) can be managed in the same way like all other records. All records have to be created in the sysfolder.

The records “album” can be created on a sysfolder or directly on the page in which it be displayed.

Configuration

The extension can be installed via the extension manager. Just be sure, that your folder permissions are set correctly.

Constant Editor Description

Change the TS Constants to your needs. Therefor create an extension template on each page created, or use you main template. To change all constants, just use the Template > Constant Editor. Two is essential : “Single” PID and “List” PID if you use TOPICLIST code.

Template file

Property

Template file

Data type

file[html,htm,tmpl,txt]

Description

URL and name of the main template, use by all the CODES.

Default

EXT:photographic_library/pi1/photographic_library_template.tmpl

"Single" pid

Property

"Single" pid

Data type

int+

Description

Uid of the SINGLE page use to do link on LIST, ALBUM and SEARCH pages

Default

"List" pid

Property

"List" pid

Data type

int+

Description

Uid of the LIST page use to do link on TOPICLIST and ALBUMLIST pages

Default

Maximum Width size

Property

Maximum Width size

Data type

int+

Description

Maximum width size for the thumbnails on LIST, ALBUM and SEARCH pages

Default

100

Maximum Height size

Property

Maximum Height size

Data type

int+

Description

Maximum height size for the thumbnails on LIST, ALBUM and SEARCH pages

Default

100

Width size

Property

Width size

Data type

int+

Description

Fixed width size for the thumbnails on LIST, ALBUM and SEARCH pages

Default

100

Height size

Property

Height size

Data type

int+

Description

Fixed height size for the thumbnails on LIST, ALBUM and SEARCH pages

Default

100

Use max size

Property

Use max size

Data type

boolean

Description

Choose between use of max size and fixed size. If is set, thumbnails is formatted with max size properties, else thumbnails is formatted with fixed size properties

Default

0

Maximum single size

Property

Maximum single size

Data type

int+

Description

Maximum size for the photo on the SINGLE page

Default

500

Number of photos

Property

Number of photos

Data type

int+

Description

Number of photos display by line on LIST, ALBUM and SEARCH pages

Default

2

Number of photos by page

Property

Number of photos by page

Data type

Int+

Description

Display list of photos on several pages with link to next and previous at the end of page. If =0, all photos are in the same page. Doesn' t work with result of a search.

Default

0

Number of line

Property

Number of line

Data type

int+

Description

Number of lines in which random photo are displayed

Default

1

Number of column

Property

Number of column

Data type

int+

Description

Number of columns in which random photo are displayed

Default

1

Single title backgroundcolor

Property

Single title backgroundcolor

Data type

color

Description

Background color for the title of the photo in the SINGLE page.

Default

#E0E0E0

Topic name wrap

Property

Topic name wrap

Data type

wrap

Description

Wrap apply to the topic name on the TOPICLIST page

Default

|

Album name wrap

Property

Album name wrap

Data type

wrap

Description

Wrap apply to the album name on the ALBUMLIST page

Default

|

Horizontal margin

Property

Horizontal margin

Data type

int+

Description

Spacing between the top of screen and the top of popup

Default

0

Vertical margin

Property

Vertical margin

Data type

int+

Description

Spacing betweeb the left of screen and the left of popup

Default

0

Pop-up width

Property

Pop-up width

Data type

int+

Description

Width of th popup with SINGLE informatrion

Default

555

Pop-up height

Property

Pop-up height

Data type

int+

Description

Height of th popup with SINGLE informatrion

Default

600

useLightBox

Property

useLightBox

Data type

Boolean

Description

Activation or desaction of Lightbox display. If is set, you don't use single code and page

Default

0

Allow comment

Property

Allow comment

Data type

boolean

Description

Activation or desactivation of FE users comments for each photos in single view

Default

0

Pid comment

Property

Pid comment

Data type

int+

Description

Uid of the sysfolde in which comments are created

Default

0

Allow guest

Property

Allow guest

Data type

boolean

Description

Allow no connected user to add comment or not

Default

0

Word guest

Property

Word guest

Data type

String

Description

Word which introduce the comment of a no connected user

Default

Guest

Wrap user

Property

Wrap user

Data type

Wrap

Description

Wrap apply to the name of user

Default

|

Wrap comment

Property

Wrap comment

Data type

Wrap

Description

Wrap apply to the comment

Default

|

Wrap date

Property

Wrap date

Data type

Wrap

Description

Wrap apply to the date of a comment

Default

|

Date format

Property

Date format

Data type

string

Description

Format apply to the date of a comment

Default

(%d/%m/%Y %H:%M:%S)

Censured words

Property

Censured words

Data type

string

Description

List of words separate by comma which are censured on comments

Default

Administration

All fields of the extension can be controlled via the ACL for backend user groups.

If you want to change the quality of thumbnails, you must modify the ext_typoscript_setup.txt on line file.params = -quality 100. To see all existing parameters go on tsref documentation.

You have a backend modul which allow to import photographics by zip files.First thing is to configure it. Go on Ext Manager->Photographic Library , at the end of table, there is the constant “PATH_FOLDER_ZIP”. You must write the path of fileadmin in which the modul go to look for zip files to import. There is the constant “PATH_PHOTO_SAVE” too. You must write the path of fileamin in which the modul go to save photo. This path must be different of the first one ( PATH_FOLDER_ZIP).

After to use the modul, follow that :

First click on modul title “Photo”, choose a sysfolder where photographics will be created, choose zip file (in list there are all zip files found on folder write on constant “PATH_FOLDER_ZIP”), add information for default value if you want. If you want to save photo on filelist (directory on constant “PATH_PHOTO_SAVE”) for future using set the box, if you want to delete zip after import set the next box and finally set the box for import and execute the import.

To check your import look at your sysfolerwith the menu list.

Known problems

Two at the moment :

  • with code ALBUM, if you use an id (with the field “Topic id (for LIST) or Album id (for ALBUM)”) this album must be on the starting point (if one is selected) or on the current page (if no starting point is selected)
  • if the backend modul don't work because it doesn't unzip, you must configure unzip_path on install menu->All configuration. On windows, unzip.exe could be not on install, you can download a good version here : http://www.mame.net/zips/compile/unzip.exe
  • The popup link (<a href=”#”...) doesn't work with extension RealURL. You must change line 602 and 650 of PHP class :

"#" become : "index.php?id='.$GLOBALS["TSFE"]->id.'”

Just email me, if you find some.

To-Do list

Clean up the extension code which is 3.5 code

  • Add some different layout for the code “LIST” and “SINGLE”,
  • Display field “Topic id (for LIST) or Album id (for ALBUM)” only if the code selected is ALBUM or LIST,
  • Correct the problem with code ALBUM,
  • Improve the layout select,
  • Add the other interesting remarks of the users,
  • Add default value for import.

Change log

  • 1.1.0: First public release,
  • 1.2.0: Handling Error :o),
  • 1.3.0: Introduction of new functionalities : TOPICLIST,
  • 1.4.0: Introduction of new functionalities : ALBUMLIST, choice of number of picture display in LIST and layout with no text, just the photo on the LIST,
  • 1.4.3: Improvement of the forms to edit photo and album and modification of the insertion interface for the extension (select box for the code list),
  • 1.5.1: Correct bug with spMarker function. Add a field "comment" for album and topic which are displayed on mouse over, add template for display of code ALBUM and improve the code of extension for future modification,
  • 1.5.2: Add management of max size or fixed size for thumbnails and add the management of quality of the thumbnails,
  • 1.6: version 1.5.2 without the bug ;o),
  • 1.6.1: The table built with code LIST is now xhtml1.0 validated. Before, it missed some <tr> and </tr> and you have sometimes <td><td>,
  • 1.7: Add of backend modul to allow import of photographics by zip file,
  • 1.8 : Add default values for backend modul (title, desciption, keywords, copyright),
  • 1.9 : Add new code RANDOM and function typolink for links,
  • 1.10 : Add previous and next link on Single view and improve compatibility between backend modul and windows,
  • 1.11: Improve and correct version1.10,
  • 1.12: Add startingpoint for TOPICLIST and ALBUMLIST, add 2 options on backend modul (delete zip and save photo on filelist) and correct some bugs,
  • 1.13 : Add constant to limit number of photos by page with code LIST. Add previous and next link at the end of page. Doesn't work with result of a search,
  • 2.0 : Add constant to choose between same page and popup for single view. Add management of FE users comments on single view. Delete use of “set_no_cache”, now extension can be indexed by indexed search. Correct bug in build of table with code LIST in one column.
  • 2.1: Add flexform for content.
  • 2.2: Add constant for use Lightbox presentation. Add link to download original photo in popup of single view

img-3 EXT: Photographic Library - 7