
==== NAME ====

Posy::Plugin::LinkExtra - Posy plugin to add extras to local links.


==== VERSION ====

This describes version ``0.41'' of Posy::Plugin::LinkExtra.


==== DESCRIPTION ====

This plugin uses information from the Posy::Plugin::FileStats plugin to add
extra information to flagged relative links that link to files in the data
directory.

For any link to a file, add the extra attribute 'posy_link' with the
arguments for what extras you want for this link.

For example:

<a href="thingie.jpg" posy_link="size">my thingie</a>

will give

<a href="thingie.jpg">my thingie</a> (4K)

The 'posy_link' attribute must be the last attribute in the link (to make it
easier to parse).

Options:

size
The size of the linked-to file, as "(size)" in K or M or bytes, depending on
how large the file is.

words
The number of words in the linked-to file (as given by the FileStats
plugin).

mod
The last-modified date of the linked-to file.

This plugin creates a 'link_extra' entry action, which should be placed
after 'parse_entry' in the entry_action list. If you are using the
Posy::Plugin::ShortBody plugin, this should be placed after 'short_body' in
the entry_action list, not before it. If you want this to process links
which have been included by the entry flavour template, then the action
should instead be placed between 'render_entry' and 'append_entry'.


==== INSTALLATION ====

Installation needs will vary depending on the particular setup a person has.


==   Administrator, Automatic   ==

If you are the administrator of the system, then the dead simple method of
installing the modules is to use the CPAN or CPANPLUS system.

    cpanp -i Posy::Plugin::LinkExtra

This will install this plugin in the usual places where modules get
installed when one is using CPAN(PLUS).


==   Administrator, By Hand   ==

If you are the administrator of the system, but don't wish to use the
CPAN(PLUS) method, then this is for you. Take the *.tar.gz file and untar it
in a suitable directory.

To install this module, run the following commands:

    perl Build.PL
    ./Build
    ./Build test
    ./Build install

Or, if you're on a platform (like DOS or Windows) that doesn't like the "./"
notation, you can do this:

   perl Build.PL
   perl Build
   perl Build test
   perl Build install


==   User With Shell Access   ==

If you are a user on a system, and don't have root/administrator access, you
need to install Posy somewhere other than the default place (since you don't
have access to it). However, if you have shell access to the system, then
you can install it in your home directory.

Say your home directory is "/home/fred", and you want to install the modules
into a subdirectory called "perl".

Download the *.tar.gz file and untar it in a suitable directory.

    perl Build.PL --install_base /home/fred/perl
    ./Build
    ./Build test
    ./Build install

This will install the files underneath /home/fred/perl.

You will then need to make sure that you alter the PERL5LIB variable to find
the modules, and the PATH variable to find the scripts (posy_one,
posy_static).

Therefore you will need to change: your path, to include
/home/fred/perl/script (where the script will be)

        PATH=/home/fred/perl/script:${PATH}

the PERL5LIB variable to add /home/fred/perl/lib

        PERL5LIB=/home/fred/perl/lib:${PERL5LIB}


==== REQUIRES ====

    Posy
    Posy::Core
    Posy::Plugin::FileStats

    File::Spec

    Test::More


==== AUTHOR ====

    Kathryn Andersen (RUBYKAT)
    perlkat AT katspace dot com
    http://www.katspace.com


==== COPYRIGHT AND LICENCE ====

Copyright (c) 2005 by Kathryn Andersen

This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.

