Quoting Yannzola <[EMAIL PROTECTED]>:

>
> kdf Wrote:
> >
> > Did you simply save the .pl file mentioned in the thread as
> > americanlife.pm and
> > try to run it,
>
> Yup. That's what I did.
>
> kdf Wrote:
> > ...or have you converted in to fit into the slimserver plugin API?
>
> Nope. I don't know how...
>
> kdf Wrote:
> > Do you have the plugin posted somewhere so we can take a look?
>
> My AmericanLife.pm plugin is exactly the "code-ish" looking copy from
> this post:
> http://lists.slimdevices.com/archives/discuss/2004-December/040268.html
> I stripped out the quoted material, and saved the lot as a .pm
>
> I'm begining to see that this was probably not the correct route to
> take. ;-) Do I need to create two files? A .pl and a .pm?

a .PM file is a loadable module for use with other perl modules.  a .PL file is
a typically a standalone script.  What was posted was intended to be run as a
command on its own, as "TAL_parser.pl" or:
perl.exe TAL_parse.pl

This, of course, requires ActivePerl to be installed. as well as the modules
(more .PM files) that this .pl file needs (in the code as:
   use HTML::TokeParser;
   use LWP::Simple;
   use Getopt::Long;
)

Those can be installed form ActivePerl using ppm.exe.

Since the code posted is not set up as a module, and not even close to what
slimserver expects for a plugin, that explains your troubles. Any perl module,
expected to be run as a plugin, must adhere to the API that slimserver is
expecting.  Most of this is, at least all the required stuff, is documented in
the help section of slimserver, under technical information.

You may want to spend some time looking at:

http://www.perl.com
http://www.activestate.com/

There are many other sites with information about Perl, as well as several great
books published by O-Reilly.  Start with "learning Perl" if you are interested.

-kdf


_______________________________________________
plugins mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/plugins

Reply via email to