Fullscreen
[Show/Hide Left Column]
[Show/Hide Right Column]

Display an attachment or a list of attachments
3d browser Print

Plugin Attach

This Wiki Plugin displays an attachment or a list of attachments. It currently works with wiki pages and tracker items.

Close
note Note
This plugin is very similar to PluginFile.


Table of contents



Usage and Parameters

To use this plugin in a wiki page, use the syntax:

Syntax for the ATTACH plugin
{ATTACH(name|file=>file.ext, page=>WikiPage, showdesc=>0|1, bullets=>0|1, image=>0|1, inline=>0|1, all=>0|1, num|id=> , dls=>0|1, icon=>0|1)} alternate hyperlink text specified with inline parameter {ATTACH}


Parameter Accepted values Default Effect Required? Since
name or file The file name of an attachment none Results in a link to the given file using the file name as the link text. Either name, file, id or num can be used to identify a single attachment. n
page A wiki page name none Links to all files attached to this page will be listed n
showdesc 0 or 1 0 The description for the attachment will be used as the link text instead of the file name when set to 1 n
bullets 0 or 1 0 Creates a bullet list of the links to the attachment(s) when set to 1 n
image 0 or 1 0 Identifies the attachment as an image, which will be displayed inline using the img tag (see Wiki-Syntax Images) n
inline 0 or 1 0 Any text between the ATTACH tags will be used as the link text when set to 1. Only the first attachment will be listed. n
all 0 or 1 0 Lists links to all attachments for the entire tiki site together with pages they are attached to when set to 1 n
num Number representing the order of an attachment in the list of attachments to a page. none Identifies the attachment to link to by order number instead of by file name. Either name, file, id or num can be used to identify a single attachment. n
id Number representing the tiki id assigned to the attachment (visible in the list of attachments at the bottom of a page) none Identifies the attachment to link to by id number instead of by file name or order number. n
dls 0 or 1 0 The alt text that pops up on mouseover will include the number of downloads of the attachment at the end when set to 1 n
icon 0 or 1 0 A file type icon is displayed in front of the attachment link when this is set to 1 n


More tips on how the plugin works:
  • Only files listed as an attachment at the bottom of a page are captured by this plugin.
    • That means that images that have been uploaded through the "Upload picture:" option on the edit panel or uploaded to an image or file gallery and only linked to on the page will not be included. Other types of files (other than images) uploaded in the edit panel will be included because they appear in the list of attachments.
  • To link directly to a single attachment, one (and only one) of the following parameters should be used: name, file, id, num
  • To list attachments, use: page or all
  • Performance problems in versions prior to 3.0 (fixed in 3.0):

Examples

These examples use the attachments on this page. Expand the list of attachments at the bottom of this page to see how the attachment information is used or displayed in the following examples.

Note: The right arrows used on this page are also an example of the ATTACH plugin where the file parameter is used. View the source to see how it works.

Using icon, showdesc and dls parameters

This code,

Using icon, showdesc and dls
{ATTACH(icon=>1, showdesc=>1, dls=>1)} {ATTACH}


arrow-right.png
Would produce on this site:



 Right arrow
 Logo for TikiWiki doc site
 This is an example file attachment
This code,

Using order number and custom link text
{ATTACH(num=>2, icon=>1, dls=>1, inline=>1)}This is the second attachment to this page {ATTACH}


arrow-right.png
Would produce on this site:


 This is the second attachment to this page

Using the ID Number and File Name

This code,

Using the id number to identify the attachment
{ATTACH(id=>10, icon=>1, dls=>1)} {ATTACH}


arrow-right.png
Would produce on this site:



 arrow-right.png


Contributors to this page: lindon1701 points  and marclaporte4510 Punkte  .
Page last modified on Tuesday 02 March, 2010 03:44:43 UTC by lindon1701 points .

To register

To have an account at this site, please register at Tikiwiki.org (external link), and then use that user name and password to log in here.

Find by Page Name

Exact match

Keywords

The following is a list of keywords that should serve as hubs for navigation within the Tiki documentation and should correspond to development keywords (bug reports and feature requests):

Accessibility (WAI – 508)
Action log 2.x
Alert 3.x
Articles & Submissions
Backlinks
Banners
Blog
Bookmark
Browser Compatibility
Cache
Calendar
Category
Chat
Clean URLs
Comments
Communication Center
Compression (gzip)
Contacts Address book
Contact us
Content template
Contribution 2.x
Cookie
Copyright
Custom Home (and Groups Home Page)
Date and Time
Debugger Console
Directory (of hyperlinks)
Documentation link from Tiki to doc.tikiwiki.org (Help System)
DogFood
Dynamic Content
Dynamic Variable
External Authentication
FAQ
Featured links
File Gallery
Forum
Friendship Network (Community)
Gmap Google maps
Groups
Hotword
HTML Page
i18n (Multilingual, l10n, Babelfish)
Image Gallery
Import-Export
Install
Integrator
Interaction
Inter-User Messages
InterTiki
Karma
Live Support
Login
Look and Feel
Lost edit protection
Mail-in
Map with Mapserver
Menu
Meta Tags
Mobile Tiki and Voice Tiki
Mods
Module
MultiTiki
MyTiki
Newsletter
Notepad
Payment
Performance Speed / Load
Permissions
Platform independence (Linux-Apache, Windows/IIS, Mac, BSD)
Polls
Profile Manager
Quicktags
Quiz
Rating
Feeds
Score
Search engine optimization
Search
Security
Semantic links 3.x
Shadowbox
Shoutbox
Slideshow
Smarty Template
Smiley
Spam protection (Anti-bot CATPCHA)
Spellcheck
Spreadsheet
Stats
Surveys
System log
Tags 2.x
Task
Tell a Friend + Social Bookmarking 2.x
TikiTests 2.x
Theme
Trackers
TRIM
User Administration including registration and banning
User Files
User Menu
Watch
WebHelp
Webmail
Webservices
Wiki 3D
Wiki History, page rename, etc
Wiki Page Staging and Approval 2.x
Wiki Plugins extends basic syntax
Wiki Syntax
Wiki structure (book and table of content)
WYSIWYCA
WYSIWYG 2.x
XMLRPC