Wikka Documentation : AttachmentInfo

HomePage :: Index :: RecentChanges :: Search :: Login/Register

Files Action Documentation

This is the documentation of the files action.

File management in Wikka is supported by adding the {{files}} action in a page.

Requirements

  1. A directory for the files has to exist.
  2. The entry upload_path in wikka.config.php] has to match the path for this directory.
  3. The web server has to be able to write to the upload_path.
  4. since 1.2
    You can use the INTRANET_MODE option to allow write access for non-admin users. Note: This option must be explicitly enabled in files/files.php, and is not currently available in wikka.config.php.
    until 1.1.6.6
    To upload files you must be an admin.
  5. To delete files you must be an admin.
  6. If you're having problems with PHP safe mode try this solution.

Show or manage attached files

  1. Insert the action {{files}} on a page.
  2. Look at the list to see the files attached to the current page, their size and the date they have been added.
  3. Filenames in the list become download links.

Upload a file


  1. since 1.2
    Admins can set the INTRANET_MODE option in files/files.php to allow uploads by non-admin users. Note: This option must be explicitly set, and is not currently available in wikka.config.php.
    until 1.1.6.6
    You must be an admin to upload files!
  2. Make sure {{files}} is on the page.
  3. Click on the Browse... button to search for a file.
  4. Select a file on your computer (you can only select one) .
  5. The name should appear in the box right next to add new attachment.
  6. Click on the "+".
  7. If you can see the file in the list, your upload was successful.

Upload and use images (with mod_rewrite enabled)
By copying an image link as displayed in the attachment box after uploading a file, you can use this link directly in the url parameter of the {{image}} action, regardless of whether or not mod_rewrite is in use.

If you choose to use a relative URL as the argument to the url parameter (for instance, url="uploads/ImagePage/myImages.jpg"), the image will not display. There is a solution for that:
  1. Create one page in which you put the file action. On this page, you should only upload images and no other files.
  2. Upload an image.
  3. Copy .htaccess from the /images directory of wikka into uploads/YourPagename.

Since the files (images) in this directory will be accessible now, i.e. you aren't redirected to Wikka, it is a bad idea to upload anything else than images on this page.


Download a file


Delete a file

You must be an admin to do this!
  1. Make sure {{files}} is on the page.
  2. Look for the file you want to delete in the list.
  3. Click on the small "x" before the file.

Examples


{{files}}
Please make sure that the server has write access to a folder named uploads.


{{files download="freemind_sample1.jpg" text="Freemind sample"}}
Please make sure that the server has write access to a folder named uploads.
Freemind sample


CategoryEN
There are no comments on this page.
Creative Common Attribution-ShareAlike License
Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by WikkaWiki
Page was generated in 0.0087 seconds