|
PLP::Fields - Special hashes for PLP |
PLP::Fields - Special hashes for PLP
For your convenience, PLP uses hashes to put things in. Some of these are tied hashes, so they contain a bit magic. For example, building the hash can be delayed until you actually use the hash.
%get and %postkey=value&key=value (or key=value;key=value
strings in query string and post content. %post is not built if the content
type is not application/x-www-form-urlencoded. In post content, the
semi-colon is not a valid separator.
%post isn't built until it is used, to speed up your script if you
don't use it. Because POST content can only be read once, you can use CGI;
and just never access %post to avoid its building.
With a query string of key=firstvalue&key=secondvalue, $get{key} will
contain only secondvalue. You can access both elements by using the array
reference $get{'@key'}, which will contain [ 'firstvalue', 'secondvalue'
].
%fields@-keys contain both values).
This hash is built on first use, just like %post.
%cookie, %cookies%header, %headers
$header{CONTENT_TYPE}
$header{'Content-Type'}
$header{Content_Type}
$headers{CONTENT_type}
Juerd Waalboer <juerd@cpan.org>
Current maintainer: Mischa POSLAWSKY <shiar@cpan.org>
|
PLP::Fields - Special hashes for PLP |