Labyrinth
view release on metacpan
or search on metacpan
Changes
view on Meta::CPAN
108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 | 5.18 2013-10-13
- removed Crypt::RandPasswd from prerequisites.
- added ResizeDimensions for displaying images (Media).
5.17 2013-05-03
- fixed &
- added Filters.pm a DFV plugin for additional parameter validation.
- fixed missing pre-requisite, Session::Token.
5.16 2013-04-28
- post-processing XHTML content before writing out is now optional,
default is no post-processing. Use 'parsehtml' config setting
(Writer).
- new 'parsetest' configuration setting to allow tests to determine
differences between original and post-processed content (Writer).
- added DumpToFile for parsetest functionality (Audit).
- fixed url validation (Variables).
- improvements to post-processing content (MLUtils).
- Enabled phrasebook caching to reduce disk I/O (Phrasebook).
- switched from Crypt::RandPasswd to Session::Token for password
generation for speed and efficiency (Users).
|
Changes
view on Meta::CPAN
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 | - moved SetLogFile into Globals and allowed more settings.
- added titles to links, with the ability to provide user mappings.
5.08 2011-06-19
- documentation updates.
- added url mapping for MetaCloud links.
- fixes for GetImageSize.
5.07 2011-06-19
- added GetImageSize & GetGravatar to Media.pm.
- added a cleanup of erroneous XHTML patterns in MLUtils.pm.
- store error message if opening mail pipe fails in Mailer.pm.
5.06 2011-05-19
- abstracted input CGI to Labyrinth::Query::CGI.
- abstracted output CGI to Labyrinth::Writer::Render::CGI.
- abstracted template parser to Labyrinth::Writer::Parser::TT.
- all above in order to allow PSGI packages and other template parsers
to be used.
- documentation updates.
- reworked CookieLib to use new Labyrinth::Query::CGI package . |
Changes
view on Meta::CPAN
240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 | - comments can be ignored or removed in MLUtils.
- '#' is valid in a URL.
- 'noscript' added to the list of valid tags.
- defaults applied to 'who' when saving IPs.
- added UserID lookup in Users.
4.16 2009-03-06
- fixed DTUtils.pm undefined error.
- simplified Metadata searches and combined photo/page searches into
a single table using nested selects
- updated MLUtils.pm with new XHTML compatibility fixes.
- removed unused Exporter references from several modules.
- removed excessive use of 'use vars' where it wasn't needed. - reduced unncessary function calls
- reduced unncessary database calls
- added protection for bad image calls (IMDriver.pm/GDDriver.pm)
- moved Plugins management to Plugins.pm
- remove whitespace before </p> in MLUtils.pm
- added demoroniser code to MLUtils.pm
4.15 2008-05-31
|
Changes
view on Meta::CPAN
372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 | - added more entries to %safe_tags (MLUtils.pm)
- improved Metadata.pm interfaces
- removed last remaining forum references
4.05 2007-03-08
- lots of fixes!
4.04 2007-02-21
- created Variables.pm to stop cyclic dependency, simplifying Globals.pm
in the process.
- improved Writer.pm so valid XHTML is correctly parsed out.
- as a result of the above extended MLUtils.pm and fixed several
hidden content bugs in the templates.
- Croak moved to Writer.pm as it's a better fit in the chain.
- removed unnecessary references to Globals.pm, Session.pm & Specific.pm
from plugins that don't use them. - SafeHTML => CleanTags in several plugins.
- undef body bugfix to images in paragraphs (Articles.pm)
- initialise event types (Events.pm)
4.03 2007-02-04
|
lib/Labyrinth/Groups.pm
view on Meta::CPAN
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 | Checks whether the specified user (or current user) is in the specified group
Returns 1 if true, otherwise 0 for false.
sub GetGroupID {
my $name = shift || return ;
my @rows = $dbi ->GetQuery( 'array' , 'GetGroupID' , $name );
return unless ( @rows );
|
lib/Labyrinth/MLUtils.pm
view on Meta::CPAN
91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 | sub LegalTag {
my $tag = lc shift ;
|
lib/Labyrinth/MLUtils.pm
view on Meta::CPAN
622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 | use vars qw(%html_entities $html_safe_chars %escape_html_map $escape_html_map) ; use vars qw(%safe_tags %safe_style %tag_is_empty %closetag_is_optional %closetag_is_dependent %force_closetag %transpose_tag
$convert_nl %auto_deinterleave $auto_deinterleave_pattern) ;
sub process_html {
my ( $text , $line_breaks , $allow_html ) = @_ ;
if ( $text ) {
$text =~ s!</pre><pre>!<br />!gsi;
$text =~ s!<ul>\s*<br />!<ul>!gsi;
$text =~ s!<br />\s*</ul>!</ul>!gsi;
$text =~ s!<ul>\s*</ul>!!gsi;
$text =~ s!<ol>\s*</ol>!!gsi;
}
|
lib/Labyrinth/MLUtils.pm
view on Meta::CPAN
1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 | return $_ ;
}
sub cleanup_tag {
my ( $tag , $attrs ) = @_ ;
unless ( exists $safe_tags ->{ $tag }) {
return '' ;
}
$tag = $transpose_tag { $tag } if ( $transpose_tag { $tag });
my $html = '' ;
if ( $force_closetag { $tag }) {
while ( scalar @stack and $force_closetag { $tag }{ $stack [0]{NAME}}) {
$html = cleanup_close( $stack [0]{NAME});
}
}
my $t = $safe_tags ->{ $tag };
|
lib/Labyrinth/MLUtils.pm
view on Meta::CPAN
1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 | unshift @stack , { NAME => $tag , FULL => $full };
$str = "$html$full" ;
}
return $str ;
}
sub cleanup_close {
my $tag = shift ;
$tag = $transpose_tag { $tag } if ( $transpose_tag { $tag });
unless ( grep { $_ ->{NAME} eq $tag } @stack ) {
return '' ;
}
my @close = ();
while ( scalar @stack and $stack [0]{NAME} ne $tag ) {
|
lib/Labyrinth/Media.pm
view on Meta::CPAN
191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 | sub StockName {
my $stock = shift || 1;
_init_stock() unless ( %stock );
|
lib/Labyrinth/Metadata.pm
view on Meta::CPAN
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 | |
lib/Labyrinth/Support.pm
view on Meta::CPAN
95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 | my %publishstates = (
1 => { Action => 'Draft' , State => 'Draft' },
2 => { Action => 'Submit' , State => 'Submitted' },
3 => { Action => 'Publish' , State => 'Published' },
4 => { Action => 'Archive' , State => 'Archived' },
);
|
lib/Labyrinth/Support.pm
view on Meta::CPAN
166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 | sub AlignName {
my $opt = shift || 1;
return $alignments { $opt }->{name};
}
sub AlignClass {
|
lib/Labyrinth/Support.pm
view on Meta::CPAN
368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 | Default permission level is ADMIN. Returns 1 if permission is granted, 0
otherwise.
|
lib/Labyrinth/Support.pm
view on Meta::CPAN
444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 | my @areas = map { "'$_->[0]'" } @rows ;
return join ( ',' , @areas );
}
|
lib/Labyrinth/Support.pm
view on Meta::CPAN
499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 | sub ProfileSelect {
my $opt = shift || 0;
my $name = shift || 'profile' ;
LoadProfiles();
my @rows = map { { profile => $_ } } sort grep { $_ ne $settings {profiles}{ default } } keys %{ $settings {profiles}{profiles}};
unshift @rows , { profile => $settings {profiles}{ default } } if ( $settings {profiles}{ default });
|
lib/Labyrinth/Support.pm
view on Meta::CPAN
535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 | sub FolderSelect {
my $opt = shift || 0;
my $name = shift || 'folderid' ;
my @rows = $dbi ->GetQuery( 'hash' , 'AllFolders' );
DropDownRows( $opt , $name , 'folderid' , 'foldername' , @rows );
}
sub AreaSelect {
my $opt = shift ;
my @rows = $dbi ->GetQuery( 'hash' , 'AllAreas' );
DropDownRows( $opt , 'area' , 'areaid' , 'title' , @rows );
}
|
lib/Labyrinth/Users.pm
view on Meta::CPAN
143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 | return 3;
}
sub UserSelect {
my $opt = shift ;
|