This page is still a beta!

8.12. TypoScript Reference

PROPERTY

DATA TYPE

DESCRIPTION

DEFAULT

templateFile

string

The template file. If you want to edit the existing, copy it out of the typo3conf/ext/wec_staffdirectory/template/ folder and then put it in fileadmin and set this constant to where you put it.

EXT:wec_staffdirectory/template/wecstaffdirectory.tmpl

imageWidth

string

The width for the main photo. This photo is normally used on the staff page. Note that the 'm' is for TYPO3 to proportionally size the width and height correctly. You can hardcode it to 200px or 200 to make it fixed at exactly 200 or whatever value you would like.

200m

imageHeight

string

The height for the main photo. This setting is normally used on the staff page. It is recommended to set just the height or width only otherwise pictures may be distorted if the original is not the same size.

smallImageWidth

string

The width for the small main photo. This setting is normally used on the staff listing.

80m

smallImageHeight

string

The height for the small main photo. This setting is normally used on the staff listing.

etcImageWidth

string

The width for the etc photos. This setting is normally used on the staff page.

120m

etcImageHeight

string

The height for the etc photos. This setting is normally used on the staff listing.

imagePhotoBlank

string

If a staff does not have a picture, this is the default blank image used. If the staff is a female (as set in fe_user), then the imagePhotoBlank2 is used if it is set. Clear this if you do not want any image displayed when no image is available.

EXT:wec_staffdirectory/res/photoblank.gif

imagePhotoBlank2

string

If a staff does not have a picture and their fe_user record shows them as female, then this blank image is used. Clear this if you do not want an image displayed.

EXT:wec_staffdirectory/res/photoblank_f.gif

emailIcon

string

If you want to support an email icon, instead of the email address shown, then you can set this. If you do not want it to display an email icon, clear this and the email will be displayed.

EXT:wec_staffdirectory/res/email_icon.jpg

social_contact1Icon

string

If you want to support social contact services, you can set a given icon here. It is initially set to Twitter, but can be changed / updated (along with locallang) to what you want.

EXT:wec_staffdirectory/res/twitter_icon.png

social_contact2Icon

string

Support for second social contact service. It is initially set to Facebook, but can be changed / updated (along with locallang) to what you want.

EXT:wec_staffdirectory/res/facebook_icon.png

social_contact3Icon

string

Support for third social contact service. It is initially set to LinkedIn, but can be changed / updated (along with locallang) to what you want.

EXT:wec_staffdirectory/res/linkedin_icon.png

sortFieldForDept

string

Enables secondary sorting when the primary sorting is for Department. Can be set to last_name, first_name, sorting_backend, or display_order.

last_name

useFEPhoto

string

Use Frontend User photo instead of the Staff Info photo.

altImagePath

string

The upload folder for images. If you have all your images stored in a different place, you can specify that here. Otherwise, they will be saved and loaded from this folder.

uploads/tx_wecstaffdirectory/

Colors

   

main_photo

IMAGE

This sets the height, width and quality. It uses the TS constants imageHeight and imageWidth for the height and width. The quality default is set to 80. The quality is set for JPEG images only and refers to the compression done on a file. With quality set to 100, there is no compression, whereas quality set below 50 will usually be very noticable. If your photos do not look good, you may want to increase the quality. If you use huge (greater than 1MB each), high-quality photo files, you may want to lower the quality.

main_photo_small

IMAGE

This sets the height, width and quality for the small image. It uses the TS constants smallImageHeight and smallImageWidth for the height and width. The quality default is set to 70. You can read above for more information on the quality setting.

photos_etc

IMAGE

This sets the height, width and quality for the miscellaneous image(s). It uses the TS constants etcImageHeight and etcImageWidth for the height and width. The quality default is set to 80. You can read above for more information on the quality setting.

biographyShort_stdWrap

string

You can set the string handling for biography short field. You can set the length of the .crop by editting this. You can also do any other TypoScript stdWrap manipulation on the biographyShort_stdWrap that you would like. Please look at the TypoScript Reference manual for more information on stdWrap.

.crop = 350|...|1

newsShort_stdWrap

string

You can set the string handling for news short field. You can set the length of the .crop by editting this. You can also do any other TypoScript stdWrap manipulation on the newsShort_stdWrap that you would like.

.crop = 350|...|1

substitutePagetitle

integer

When a user goes to the staff person's page, this  shows the person's name in the page title of the browser. If you do not want this behavior, set this to 0.

1

Multi-language

The text used in this extension has been placed in the typo3conf/ext/wecstaffdirectory/ folder under pi1/locallang.xml file (for what you see on-screen/front-end) and locallang_db.xml file (to change the backend labels). You can extend to support different languages by adding translations to this file.

To configure a different language, you should refer to the TYPO3 documentation and check out the one-tree-fits-all-languages at  http://typo3.org/documentation/tips-tricks/multi-language-sites-in-typo3/.

As an overview, you would add the multiple languages in the root of the site, and then set something like the following in TypoScript of the site template:

# Set up the language variable "L" to be passed along with links

config.linkVars = L

# For German/Deutsch language, sys_language.uid = 2

config.sys_language_uid = 2

config.language = de

config.locale_all = de_DE

# For Dutch language, ...

config.sys_language_uid = 1

config.language = dk

config.locale_all = danish

Then, an important aspect of multiple languages is being able to edit them. One thing you must do is to set the “Localization view” option box at the bottom of the screen of the List view. This will allow you to see and set the localization (multiple language) options for records.