1 # Blosxom Plugin: fauxami
2 # Author(s): Rael Dornfest <rael@oreilly.com>
4 # Documentation: See the bottom of this file or type: perldoc whoami
8 # --- Configurable variables -----
10 # What should I consider a delimiter between poster's name
11 # and the rest of the filename (e.g. . for jack.story1.txt)?
14 # What should I fall back to as the default name (leave blank for none)?
15 my $default_name = '';
17 # --------------------------------
28 my($pkg, $path, $filename, $story_ref, $title_ref, $body_ref) = @_;
30 $name = $filename =~ m!^(.+)$delimiter(.+)$! ? $1 : $default_name;
41 Blosxom Plug-in: fauxami
45 Populates $fauxami::name with the "name" of the person
46 posting the weblog entry, using anything before a specified delimiter
47 ( the default is . ) as the "name." So, jack.story1.txt would yield
48 a $fauxami::name of jack and jill.story2.txt would yield a $fauxami::name
51 You can optionally provide a $default_name, used when no faux name is
58 Version number coincides with the version of Blosxom with which the
59 current version was first bundled.
63 Rael Dornfest <rael@oreilly.com>, http://www.raelity.org/
67 Blosxom Home/Docs/Licensing: http://www.raelity.org/apps/blosxom/
69 Blosxom Plugin Docs: http://www.raelity.org/apps/blosxom/plugin.shtml
73 Address bug reports and comments to the Blosxom mailing list
74 [http://www.yahoogroups.com/group/blosxom].
78 Blosxom and this Blosxom Plug-in
79 Copyright 2003, Rael Dornfest
81 Permission is hereby granted, free of charge, to any person obtaining a
82 copy of this software and associated documentation files (the "Software"),
83 to deal in the Software without restriction, including without limitation
84 the rights to use, copy, modify, merge, publish, distribute, sublicense,
85 and/or sell copies of the Software, and to permit persons to whom the
86 Software is furnished to do so, subject to the following conditions:
88 The above copyright notice and this permission notice shall be included
89 in all copies or substantial portions of the Software.
91 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
92 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
93 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
94 THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
95 OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
96 ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
97 OTHER DEALINGS IN THE SOFTWARE.