TetraBB PRO Documentation

Multiple file upload

The new TetraBB PRO file upload feature is a powerfull enhancement compared to the very basic image upload available in Tetra-WebBBS.
PRO file upload by design is neither limited to a specific type of file nor is it limited to any number of uploads allowed and, even better, all uploaded files are embedded into the message text of a post.
However, boardadmins may configure the upload feature in various ways to determine exactly which files can be uploaded and how they are displayed to the user. Overall a very detailed configuration of TetraBB PRO file upload is available.

Basics on file upload

  • The PRO upload utility allows for two categories of uploads:
    (1) media files (e.g: images, videos, audiofiles)
    (2) attachements (e.g.: *.zip, *.tar, *.doc, *.ppt or any other type which is no media file)
    Either, both or none can be enabled/disabled for the site. The global setting ON/OFF can be overwritten in section(3) of public entry scripts to a specific forum.
  • For a maximum security file types allowed for upload must be explicitely specified in the configs by file extension and  MIME type. On upload the file's extension and MIME type are verified to match an entry in the list of allowed file types.
  • All uploaded files are embedded directly into the messagetext of posts.
    When the poster uploads a file to the server a special codeblock gets inserted at the position of the cursor (if the cursor is in the textarea field of the postform) or at the end of the text written so far. On submission of the post this special codeblock is replaced by HTML code.
  • The way uploaded files are presented to the user is determined by a detailed configuration which allows to assign some HTML code for each type of file or for a set of similar files (e.g. different image formats). This subfeatures works similiar to the formatting button configuration. As a result the boardowner keeps full control over how things will look on the pages including the option to apply further presentation rules via CSS!
  • File size limits can be set for each type of file allowed for upload.
    E.g.: boardadmins may allow to upload videos to a maximum size of 10000 KB whereas images must not be larger than 200 KB.

Requirement

For determining the MIME type of uploaded files the Perl module File::MMagic must be available on the server.
Fortunately it's simple to install File::MMagic even if the siteowner doesn't have privileges of server administration.

Optional configuration of file uploads

  • position, size and behaviour of the upload field on message post forms is configurable:
    (1) display the field above or below the textarea field used for message texts
    (2) define the width of the input field used for file upload
    (3) start upload automatically when the user selects a file on his harddrive or optionally display a submit button next to the upload field to start the upload manually.
  • On upload files are stored in a temporary folder until the post is submitted definitely. A housekeeping routine deletes those temporary uploaded files based on a special configuration variable which determines the number of minutes to elapse before a file is considered to be expired.

CSS formatting

All uploaded files are embedded directly into the messagetext. HTML code used for each type of file or each subset of similiar files (e.g. different image formats) is configurable. Thus it's possible to assign whatsoever CSS to the codeblock associated with the uploaded files.

Example:
Think about uploading multiple images, which likely is a common desire.
Boardadmins may control the way these uploaded images are formatted by assigning the appropriate CSS specifications
- for maximum width/height in order not to screw up a site layout
- to let the image float to the left or right or center it on a page
- for margins, borders ...

in other words: you may use CSS to fancy-up the appearance of uploaded files - specific for each type of file!

Third-party tools to present video and audio files

Depending on the character, topic and audience of a site boardadmins may chose to allow uploads of videos or audiofiles.
For embedding these files into the messagetext there are several options. One may decide to use HTML code found in a tutorial on webdesign. One may as well opt to use third-party tools of various kind, e.g. use some free and embeddable video player for uploaded videofiles. Fortunately it's pretty simple to configure TetraBB PRO to make use of third-party tools for display of uploaded files. - We've tested with various players for video and audio files so we're confident there are enough options for site admins to chose from.