Apache::PerlSections man page on OpenServer

Man page or keyword search:  
man Server   5388 pages
apropos Keyword Search (all sections)
Output format
OpenServer logo
[printable version]

Apache::PerlSections(3User Contributed Perl DocumentatiApache::PerlSections(3)

NAME
       Apache::PerlSections - Utilities for work with <Perl> sections

SYNOPSIS
	   use Apache::PerlSections ();

DESCRIPTION
       It is possible to configure you server entirely in Perl using <Perl>
       sections in httpd.conf.	This module is here to help you with such a
       task.

METHODS
       dump
	   This method will dump out all the configuration variables mod_perl
	   will be feeding the the apache config gears.	 The output is suit-
	   able to read back in via "eval".

	   Example:

	    <Perl>

	    use Apache::PerlSections ();

	    $Port = 8529;

	    $Location{"/perl"} = {
		SetHandler => "perl-script",
		PerlHandler => "Apache::Registry",
		Options => "ExecCGI",
	    };

	    @DocumentIndex = qw(index.htm index.html);

	    $VirtualHost{"www.foo.com"} = {
		DocumentRoot => "/tmp/docs",
		ErrorLog => "/dev/null",
		Location => {
		    "/" => {
			Allowoverride => 'All',
			Order => 'deny,allow',
			Deny  => 'from all',
			Allow => 'from foo.com',
		    },
		},
	    };

	    print Apache::PerlSections->dump;

	    </Perl>

	   This will print something like so:

	    package Apache::ReadConfig;
	    #scalars:

	    $Port = 8529;

	    #arrays:

	    @DocumentIndex = (
	      'index.htm',
	      'index.html'
	    );

	    #hashes:

	    %Location = (
	      '/perl' => {
		PerlHandler => 'Apache::Registry',
		SetHandler => 'perl-script',
		Options => 'ExecCGI'
	      }
	    );

	    %VirtualHost = (
	      'www.foo.com' => {
		Location => {
		  '/' => {
		    Deny => 'from all',
		    Order => 'deny,allow',
		    Allow => 'from foo.com',
		    Allowoverride => 'All'
		  }
		},
		DocumentRoot => '/tmp/docs',
		ErrorLog => '/dev/null'
	      }
	    );

	    1;
	    __END__

       store
	   This method will call the "dump" method, writing the output to a
	   file, suitable to be pulled in via "require".

	   Example:

	      Apache::PerlSections->store("httpd_config.pl");

	      require 'httpd_config.pl';

SEE ALSO
       mod_perl(1), Data::Dumper(3), Devel::Symdump(3)

AUTHOR
       Doug MacEachern

perl v5.8.8			  2007-03-30	       Apache::PerlSections(3)
[top]
                             _         _         _ 
                            | |       | |       | |     
                            | |       | |       | |     
                         __ | | __ __ | | __ __ | | __  
                         \ \| |/ / \ \| |/ / \ \| |/ /  
                          \ \ / /   \ \ / /   \ \ / /   
                           \   /     \   /     \   /    
                            \_/       \_/       \_/ 
More information is available in HTML format for server OpenServer

List of man pages available for OpenServer

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net