Catalyst Zorpia
Catalyst Zorpia! :)
Perl is not the whole part of life. I know!
<xml><message>OK</message></xml>
<xml><message>OK</message><message>DEL</message></xml>
for (i = 0; i <>不管有多少个 messages, 一律强制使用 array
JSAN.use('XML.ObjTree');
var xotree = new XML.ObjTree();
xotree.force_array = [ "message" ];
var tree = xotree.parseXML( response );
Labels: javascript
use Catalyst qw/将 URI 放在 Cookie 的前面。Session::State::URI 会判断有没有 load State::Cookie 而且 cookie 有没有效。如果 cookie 有效就使用 cookie, 无效就使用 uri.
-Debug
Dumper
Config::ConfigLoader
Static::Simple
Authentication
Authentication::Store::DBIC
Authentication::Credential::Password
Session
Session::Store::DBIC
Session::State::URI
Session::State::Cookie
/;
use Sys::Hostname;
use Socket;
my $host = hostname();
my $address = inet_ntoa( scalar gethostbyname( $host || 'localhost' ) );
print $address
my $sid = $c->req->param('sid');
$c->log->debug("sid is $sid");
my $session_data = $c->get_session_data("session:$sid");
return $c->res->body(Dumper($session_data));