File: test_fcgi.pl

package info (click to toggle)
libnetsds-perl 1.301-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 296 kB
  • sloc: perl: 1,516; makefile: 7
file content (33 lines) | stat: -rwxr-xr-x 488 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/usr/bin/env perl 

use Data::Dumper;

MyApp->run;

print Dumper($c);

1;

package MyApp;

use Data::Dumper;

use base 'NetSDS::App::FCGI';

sub process {

	my ($this) = @_;

	#$this->redirect("/here");
	$this->set_cookie(name => "name1", value => '123123');
	$this->set_cookie(name => "here", value => 'ggggg', expires => "+1h");

	$this->mime('text/xml');
	$this->charset('koi8-u');
	$this->data('<html>Here is some HTML ;-)</html>');

	print Dumper($this->get_cookie('val'));
}

1;