Ryan Hunt | 17 Jul 21:26

Config Plugin

I have never been able to get the config plugin working correctly,  
and am not sure if I am doing things right.

I copied the 00config file to $datadir/category/config

Even though I have specified 10 posts in this config, I still only  
get the 1 specified in the master configuration.

Am I doing this wrong?

-Ryan

I added the following lines so the file looks like this:

# Blosxom Plugin: config
# Author(s): Rael Dornfest <rael@...>
# Version: 2003-03-18
# Documentation: See the bottom of this file or type: perldoc config

# WARNING: DO NOT PUT CONFIG FILES IN WORLD-READABLE PLACES SUCH AS  
WITHIN
# YOUR DOCUMENT ROOT.  IF YOUR $DATADIR IS LOCATED WITHIN YOUR  
DOCUMENT ROOT,
# I HEARTILY ADVISE THAT YOU MOVE IT.  WHILE MOST OF THE CONFIGURATION
# DIRECTIVES ARE INNOCUOUS ENOUGH, IT'S A SLIPPERY SLOPE AND YOU  
MIGHT WELL
# FIND YOU'VE EXPOSED YOUR STATIC PASSWORD OR INTERNAL DIRECTORY  
STRUCTURE
# TO ANYONE WITH A WEB BROWSER!

package config;

# --- Configurable variables -----
# How many entries should I show on the home page?
$num_entries = qq{10};

# --------------------------------

sub start {
   1;
}

sub entries {

   for (;;) {
     do {
       -r "$blosxom::datadir/$blosxom::path_info/config. 
$blosxom::flavour" and eval { require "$blosxom::datadir/ 
$blosxom::path_info/config.$blosxom::flavour" } and ( $@ ? warn $@ :  
last );
       -r "$blosxom::datadir/$blosxom::path_info/config" and eval  
{ require "$blosxom::datadir/$blosxom::path_info/config" } and ( $@ ?  
warn $@ : last );
     } while ($path =~ s/(\/*[^\/]*)$// and $1);
     last;
   }

   return undef;
}

1;

__END__

=head1 NAME

Blosxom Plug-in: config

=head1 SYNOPSIS

Override Blosxom's inline configuration settings on a per-directory,  
per-flavour, and per-directory-per-flavour basis.

=head1 VERSION

2003-03-18

=head1 AUTHOR

Rael Dornfest  <rael@...>, http://www.raelity.org/

=head1 SEE ALSO

Blosxom Home/Docs/Licensing: http://www.raelity.org/apps/blosxom/

Blosxom Plugin Docs: http://www.raelity.org/apps/blosxom/plugin.shtml

=head1 BUGS

Address bug reports and comments to the Blosxom mailing list
[http://www.yahoogroups.com/group/blosxom].

=head1 LICENSE

Blosxom and this Blosxom Plug-in
Copyright 2003, Rael Dornfest

Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the  
"Software"),
to deal in the Software without restriction, including without  
limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,  
EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/

Gmane