SYNOPSIS
use Egg qw/ Filter /;
# The received form data is filtered.
$e->filter(
myname => [qw/hold_html abs_strip trim/],
address=> [qw/hold_html crlf:2 abs_strip trim/],
tel => [qw/hold phone/],
);
# Cookie is filtered.
my $cookie= $e->filter( {
nick_name=> [qw/strip_html abs_strip trim/],
email => [qw/hold_html hold/],
}, $e->request->cookies );
It is filter plugin to pass it as for data.
FILTERS
trim
The space character in the back and forth is deleted.
hold
The space character is deleted.
strip
The continuousness of the space character is substituted for one half angle space.
hold_tab
The tab is deleted.
space
Consecutive half angle space is settled in one.
crlf:[NUM]
A consecutive changing line is settled in [NUM] piece. * The tab is deleted.
Default when [NUM] is omitted is 1.
strip_tab
Continuousness in the tab is substituted for one half angle space.
hold_crlf
It is 'hold' for changing line and the tab.
strip_crlf
It is 'strip' for changing line and the tab.
hold_html
The character string seen the HTML tag is deleted.
strip_html
The character string seen the HTML tag is substituted for one half angle space.
escape_html
HTML::Entities::encode_entities is done.
digit
It deletes it excluding the normal-width figure.
alphanum
It deletes it excluding the alphanumeric character.
integer
It deletes it excluding the integer.
pos_integer
It deletes it excluding the positive integer.
neg_integer
It deletes it excluding the negative integer.
decimal
It deletes it excluding the integer including small number of people.
pos_decimal
It deletes it excluding a positive integer including small number of people.
neg_decimal
It deletes it excluding a negative integer including small number of people.
dollars
It deletes it excluding the figure that can be used with dollar currency.
lc
lc is done.
uc
uc is done.
ucfirst
ucfirst is done.
phone
The character that cannot be used by the telephone number is deleted.
sql_wildcard
'*' is substituted for '%'.
quotemeta
quotemeta is done.
email
The domain name part in the mail address is converted into the small letter.
MyName@DOMAIN.COM => MyName@domain.com
url
The domain name part in the URL is converted into the small letter.
http://MYDOMAIN.COM/Hoge/Boo.html => http://mydomain.com/Hoge/Boo.html
Product's homepage
Requirements:
· Perl