use strict;
use warnings;
-use Exporter qw(import);
+use base 'Exporter';
use Fcntl qw(:flock);
our $VERSION = '1.00';
$PLP::inA = 0;
$PLP::inB = 0;
local $@;
- eval 'package PLP::Script; ' . PLP::source($PLP::file, 0, join ' ', (caller)[2,1]);
+ eval 'package PLP::Script; no warnings; ' . PLP::source($PLP::file, 0, join ' ', (caller)[2,1]);
if ($@) {
PLP::Functions::exit() if $@ =~ /\cS\cT\cO\cP/;
PLP::error($@, 1);
sub Entity (@) {
my $ref = defined wantarray ? [@_] : \@_;
for (@$ref) {
+ defined or next;
eval {
s/&/&/g;
s/"/"/g;
sub DecodeURI (@) {
my $ref = defined wantarray ? [@_] : \@_;
for (@$ref) {
+ defined or next;
eval {
tr/+/ /; # Browsers do tr/ /+/ - I don't care about RFCs, but
# I do care about real-life situations.
sub EncodeURI (@) {
my $ref = defined wantarray ? [@_] : \@_;
for (@$ref) {
+ defined or next;
eval {
s{([^A-Za-z0-9\-_.!~*'()/?:@\$,])}{sprintf("%%%02x", ord $1)}ge;
};