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: Guestbook¶
Author: | Christopher |
---|---|
Created: | 2010-12-18T19:57:23 |
Changed: | 2018-06-09T14:57:00 |
Classification: | tt_guest |
Description: | The keywords help with categorizing and tagging of the manuals. You can combine two or more keywords and add additional keywords yourself. Please use at least one keyword from both lists. If your manual is NOT in english, see next tab “language” —- forEditors (use this for editors / german “Redakteure”) forAdmins (use this for Administrators) forDevelopers (use this for Developers) forBeginners (manuals covering TYPO3 basics) forIntermediates (manuals going into more depth) forAdvanced (covering the most advanced TYPO3 topics) see more: http://wiki.typo3.org/doc_template#tags —- |
Keywords: | forEditors, forBeginners |
Author: | Franz Holzinger |
Email: | franz@ttproducts.de |
Language: | en |
EXT: Guestbook¶
Extension Key: tt_guest
Language: en
Version: 1.7.0
Keywords: forEditors, forBeginners
Copyright 2006-2018, Franz Holzinger, <franz@ttproducts.de>
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.org
Table of Contents¶
`EXT: Guestbook 1 <#__RefHeading__5708_1738894311>`_
`Introduction 3 <#__RefHeading__1741_851200283>`_
`Configuration 4 <#__RefHeading__1745_851200283>`_
class.tx_ttguest.php properties 6
`Known problems 9 <#__RefHeading__1761_851200283>`_
`To-Do list 10 <#__RefHeading__1763_851200283>`_
`Changelog 11 <#__RefHeading__1765_851200283>`_
Configuration¶
Note:¶
Only those settings which can be found using the Constants Editor or in the file ext_typoscript_constants.txt are valid constants. You must include the ‘Guestbook Old Style’ or the ‘Guestbook CSS Style’ into your ‘static template records’ of your TYPO3 template.
Spam:¶
Use the spamWords constant and add your own spam words.
Example :
spamWords := addToList(bad phrase, V1agra)
Collect the IP addresses of the users who sent you too many spams and protect your whole website by putting those IP addresses into your .htaccess file. Or insert the IP addresses inside of the Directory clauses of an apache config file. See http://www.javascriptkit.com/howto/htaccess5.shtml
Example :
...
order allow,deny
deny from 195.225.177.12 87.118.112.253 81.177.14.45
allow from all
...
Privacy Policy:¶
You must set the constant PIDprivacyPolicy to the page id which shows your DSGVOor GDPR information. This is a legal requirement. You must use a front end registration extension to register the users. They must already have agreed to your privacy policy.
If you use the forum without logged in front end users, then a privacy policy checkbox will appear in the forum entry form. You can overwrite the default texts by the _LOCAL_LANG setup.
Example :
plugin.tt_guest
plugin.tt_guest {
_LOCAL_LANG {
privacy_policy.title = PRIVACY AGREEMENT
privacy_policy.acknowledgement = The GDPR is applied.
privacy_policy.approval_required = You must approve it.
privacy_policy.acknowledged = You acknowledge to have read the privacy policy.
privacy_policy.acknowledged_2 = You acknowledge that your entered data may be processed according to GDPR.
privacy_policy.hint = You can withdraw this again.
Captcha:¶
Install the extension sr_freecap. The default constants is empty. Set the constants to “captcha = freecap”. This will enable the display of a captcha display in your post forms.
An alternative is the extension captcha. Set the constants to “captcha = captcha”.
Files: ^^^^^^
Controller/RegisterPluginController.php¶
File
Controller/RegisterPluginController.php
Description
Main class used to display the guestbook and form
Controller/Submit.php¶
File
Controller/Submit.php
Description
Used with FEDATA to submit guestbook entries to the database. See static_template ‘plugin.tt_guest’
Properties:
.notifyEmail = email address that should be notified of submissions.
guest_template1.tmpl guest_template2.tmpl¶
File
guest_template1.tmpl guest_template2.tmpl
Description
Example template files. ‘guest_template1.tmpl’ is default with static_template ‘plugin.tt_guest’
constants.txt¶
File
constants.txt
setup.txt
Description
You must include the static template ‘CSS styled content’.
Description¶
The default guest book consists of two main files, class.tx_ttguest.php (display) and guest_submit.inc (submission to database) plus two example templates, guest_template[x].tmpl.
If you want to create a guestbook out-of-the-box you should include the static template ‘plugin.tt_guest’ and create a content element of the “List” type and enter a certain code. For a visual introduction to this, please see the example on the Typo3 testsite (page id 15).
class.tx_ttguest.php properties¶
templateFile¶
Property
templateFile
Data type
resource
Description
The template-file.
See examples like ‘media/scripts/guest_template1.tmpl’
Default
alternatingLayouts¶
Property
alternatingLayouts
Data type
integer
Description
Indicates how many alternating design the guestbook should expect.
If you define a subpart like “<!–###POST###–> … <!–###POST###–>” this is used al the time.
If you define a similar subpart “<!–###POST_1###–> … <!–###POST_1###–>” which might show another set of colors, this is used every second time instead of the default! This is because “alternateLayouts” is set to 2
If you define a similar subpart “<!–###POST_2###–> … <!–###POST_2###–>” … this will be used every third time IF (!) “alternateLayouts” is set to 3. If you do now set it to three, the first two will be used only.
Default
2
pid_list¶
Property
pid_list
Data type
string / stdWrap
Description
The pid’s from where to fetch the items. Default is the current page. Accepts multiple pid’s commaseparated!
Default
PIDprivacyPolicy¶
Property
PIDprivacyPolicy
Data type
int+
Description
PID for the privacy policy page in the TYPO3 page tree. On this page you must publish the privacy policy according to DSGVOand GDPR . If you have set this page and no memberOfGroups is set, then an additional privacy confirmation checkbox will appear.
Default
code¶
Property
code
Data type
string / stdWrap
Description
Code to define, what the script does. Case sensitive
Default
data entry form (POSTFORM)¶
Property
data entry form (POSTFORM)
guestbook list
(GUESTBOOK)
Data type
Creates a form from which to post a new guest-book entry.
Shows the content of the current guestbook (from the pid(‘s)).
defaultCode¶
Property
defaultCode
Data type
string
Description
The default code (see above) if the value is empty. By default it’s not set and a help screen will appear
Default
date_stdWrap¶
Property
date_stdWrap
Data type
->stdWrap
Description
stdWrap for display of dates.
Example:
date_stdWrap.strftime= %e-%m-%y
Default
time_stdWrap¶
Property
time_stdWrap
Data type
->stdWrap
Description
stdWrap for display of time.
Example:
time_stdWrap.strftime= %H:%M:%S
Default
age_stdWrap¶
Property
age_stdWrap
Data type
->stdWrap
Description
stdWrap for display of ages.
Example:
age_stdWrap.age = 1
Default
title_stdWrap¶
Property
title_stdWrap
Data type
->stdWrap
Description
stdWrap for display of the title field
Default
note_stdWrap¶
Property
note_stdWrap
Data type
->stdWrap
Description
stdWrap for display of the note field
Default
author_stdWrap¶
Property
author_stdWrap
Data type
->stdWrap
Description
stdWrap for display of the author field
Default
email_stdWrap¶
Property
email_stdWrap
Data type
->stdWrap
Description
stdWrap for display of the email field
Default
www_stdWrap¶
Property
www_stdWrap
Data type
->stdWrap
Description
stdWrap for display of the www field
Default
subpartMarker¶
Property
subpartMarker
Data type
string
Description
The “marker” that defines the subpart to use from the template.
(see the template example files)
Default
TEMPLATE_GUESTBOOK
postform¶
Property
postform
Data type
->FORM cObject
Description
Configuration of the form for posting replyes and possibly also new threads.
By default this is based on styles.content.mailform and extended with other fields.
Default
requireRecords¶
Property
requireRecords
Data type
boolean
Description
If set, this script will return the comments only if there are comments. If not set the comment header will display no matter what.
Default
dontParseContent¶
Property
dontParseContent
Data type
boolean
Description
Normally the content which is output it htmlspecialchar’ed and nl2br’ed. This flag prevents that.
Default
displayCurrentRecord¶
Property
displayCurrentRecord
Data type
boolean
Description
If set, certain settings are manipulated in order to let the script render a single item - the $cObj->data.
Used to display single items forcibly.
Default
wrap1¶
Property
wrap1
Data type
-> stdWrap
Description
Global Wrap 1. This will be splitted into the markers ###GW1B### and ###GW1E###. Don’t change the input value by the settings, only wrap it in something.
Example:
wrap1.wrap = <b> |</B>
Default
wrap2¶
Property
wrap2
Data type
-> stdWrap
Description
Global Wrap 2 (see above)
Default
color1¶
Property
color1
Data type
string /stdWrap
Description
Value for ###GC1### marker (Global color 1)
Default
color2¶
Property
color2
Data type
string /stdWrap
Description
Value for ###GC2### marker (Global color 2)
Default
color3¶
Property
color3
Data type
string /stdWrap
Description
Value for ###GC3### marker (Global color 3)
Default
[tsref:(script).guestLib]
Submit.php properties¶
spamWords¶
Property
spamWords
Data type
string
Description
Comma separated list of words. A post will be considered as spam if one of these words is found in the note.
Default
notifyEmail¶
Property
notifyEmail
Data type
string
Description
Email address where to send the notification of new entries into the guestbook.
Default
Constants:¶
Property
Constants:
emailCheck
Data type
boolean
Description
If set the email address will be checked if it exists. Otherwise no entry will be made and an error message gets displayed.
Default
Constants:¶
Property
Constants:
captcha
Data type
string
Description
Usage of the captcha security string.
Set this to freecap and install sr_freecap.
Or set this to captcha and install captcha.
Default
Known problems¶
- This guestbook does not have so many possibilities like other guest books.
- You must include the tt_guest default template (Guestbook CSS Style) in the template module ‘Include static (from extensions)’.
To-Do list¶
- Write a new guestbook extension with more features.
- Related the guestbook items back to the content element inserting it - thus we can have more guestbooks on a single page.
- Search mailbox for more…