Download Shareware and Freeware Software for Windows, Linux, Macintosh, PDA

line Home  |  About Us  |  Link To Us  |  FAQ  |  Contact

Serving Software Downloads in 976 Categories, Downloaded 29.545.393 Times

CGI::Portable 0.51

  Date Added: March 27, 2010  |  Visits: 782

CGI::Portable

Report Broken Link
Printer Friendly Version


Product Homepage
Download (76 downloads)



CGI::Portable is a framework for server-generic web apps. SYNOPSIS Content of thin shell "startup_cgi.pl" for CGI or Apache::Registry env: #!/usr/bin/perl use strict; use warnings; require CGI::Portable; my $globals = CGI::Portable->new(); use Cwd; $globals->file_path_root( cwd() ); # let us default to current working directory $globals->file_path_delimiter( $^O=~/Mac/i ? ":" : $^O=~/Win/i ? "" : "/" ); $globals->set_prefs( config.pl ); $globals->current_user_path_level( 1 ); require CGI::Portable::AdapterCGI; my $io = CGI::Portable::AdapterCGI->new(); $io->fetch_user_input( $globals ); $globals->call_component( DemoAardvark ); $io->send_user_output( $globals ); 1; Content of thin shell "startup_socket.pl" for IO::Socket::INET: #!/usr/bin/perl use strict; use warnings; print "[Server $0 starting up]n"; require CGI::Portable; my $globals = CGI::Portable->new(); use Cwd; $globals->file_path_root( cwd() ); # let us default to current working directory $globals->file_path_delimiter( $^O=~/Mac/i ? ":" : $^O=~/Win/i ? "" : "/" ); $globals->set_prefs( config.pl ); $globals->current_user_path_level( 1 ); require CGI::Portable::AdapterSocket; my $io = CGI::Portable::AdapterSocket->new(); use IO::Socket; my $server = IO::Socket::INET->new( Listen => SOMAXCONN, LocalAddr => 127.0.0.1, LocalPort => 1984, Proto => tcp ); die "[Error: cant setup server $0]" unless $server; print "[Server $0 accepting clients]n"; while( my $client = $server->accept() ) { printf "%s: [Connect from %s]n", scalar localtime, $client->peerhost; my $content = $globals->make_new_context(); $io->fetch_user_input( $content, $client ); $content->call_component( DemoAardvark ); $io->send_user_output( $content, $client ); close $client; printf "%s http://%s:%s%s %sn", $content->request_method, $content->server_domain, $content->server_port, $content->user_path_string, $content->http_status_code; } 1; ^The CGI::Portable class is a framework intended to support complex web applications that are easily portable across servers because common environment-specific details are abstracted away, including the file system type, the web server type, and your projects location in the file system or uri hierarchy. Also abstracted away are details related to how users of your applications arrange instance config/preferences data across single or multiple files, so they get more flexability in how to use your application without you writing the code to support it. So your apps are easier to make data-controlled. Application cores would use CGI::Portable as an interface to the server they are running under, where they receive user input through it and they return a response (HTML page or other data type) to the user through it. Since CGI::Portable should be able to express all of their user input or output needs, your application cores should run well under CGI or mod_perl or IIS or a Perl-based server or a command line without having code that supports each types individual needs. That said, CGI::Portable doesnt contain any user input/output code of its own, but allows you to use whatever platform-specific code or modules you wish between it and the actual server. By using my module as an abstraction layer, your own program core doesnt need to know which platform-specific code it is talking to. As a logical extension to the interfacing functionality, CGI::Portable makes it easier for you to divide your application into autonomous components, each of which acts like it is its own application core with user input and instance config data provided to it and a recepticle for its user output provided. This module would be an interface between the components. This class has 5 main types of functionality, or sets of properties that exist in parallel but are fully/mostly independant from each other. As such, it could conceptually be split into 5 physical modules, some of which could be used on their own, but they are actually contained in this one module for simplicity of use (just one object for user code to keep track of). The 5 functionality sets could be called: Errors, Files, Request, Response, Misc..

Requirements: No special requirements
Platforms: Linux
Keyword: Cgi Cgiportable Code File Io Libraries New Path Programming Server User
Users rating: 0/10

License: Freeware Size: 95.23 KB
USER REVIEWS
More Reviews or Write Review


CGI::PORTABLE RELATED
Libraries  -  CGI::Builder::Auth::UserAdmin 0.06
CGI::Builder::Auth::UserAdmin is a Perl module for the management of HTTP server user databases. SYNOPSIS use CGI::Builder::Auth::UserAdmin (); Pay no attention to that man behind the curtain! Move along, nothing to see here! This module...
51.2 KB  
Audio Tools  -  w98podfetch 0.61
w98podfetch is a script that uses an XML configuration file to retrieve new podcast files from feeds you have subscribed to. Each subscription is listed in the main configuration file, and the script can set limitations such as "dont download...
20.48 KB  
Libraries  -  Language::Zcode::Parser 0.8
Language::Zcode::Parser is a Perl module that reads and parses a Z-code file into a big Perl hash. SYNOPSIS # Create a Pure Perl Parser my $pParser = new Language::Zcode::Parser "Perl"; # If they didnt put ".z5" at the end, find it anyway...
296.96 KB  
Programming  -  Transmuter Programming Language 0.9.2
Transmuter Programming Language is an extremely dynamic, biologically-inspired prototyping language providing a framework for experimenting with naturally evolving systems of objects over the net, and for exploring new ideas about recombinant...
348.16 KB  
Libraries  -  File::Basename::Object 0.01
File::Basename::Object is a Perl module with object-oriented syntax sugar for File::Basename. SYNOPSIS my $file = File::Basename::Object->new("/path/to/a/file.html", ".htm", ".html"); if(open(my $fh, <, $file)) { print "Now reading ",...
4.1 KB  
Libraries  -  Libsdf 0.1
Libsdf library is a shared library which, when preloaded, will intercept calls to a GNU libc functions open() and open64(), and if the first argoment of these functions is a remote file (http:// or ftp://), it will copy this file in a local path...
10.24 KB  
Development Editors  -  ACQC Metrics 1.0.3
The ACQC Metrics application was developed to be a small tool that computes typical source code file and function metrics. What are metrics good for? Well, it measures the software in terms of complexity for example. Very long or complex...
 
Development Editors  -  EziEditDat 1.00
Developers: do you hate having to write more code to configure your new program? Wouldn't it be great if you could just run something and have it manage the user's chosen configuration? Well, EziEditDat may be just what you're looking for. It uses...
133.12 KB  
Entertainment Tools  -  prweb coupon code 1.0
prweb coupon code and PRWEB Promo Code Network Software Module New Release
6.77 MB  
Business  -  PartCopy 1.11.2.4
This utility can copy any number of bytes from one file into a new one. Useful if you want to extract sound or data from a location within a file. PartCopy is a useful tool that can copy any number of bytes from one file into a new one. Useful if...
532 KB  
NEW DOWNLOADS IN PROGRAMMING, LIBRARIES
Programming  -  FLEX-db Digital Asset Manager 3.0.9
FLEX-db - an enterprise Digital Asset Manager (DAM). It ingests and links metadata with files, creates thumbnails, and processes files using business rules. FLEX-db has a JSP client, Java app server for file input and output and an EJB metadata...
21.57 MB  
Programming  -  Libicom 0.9.0
The libicom library is a character based dynamicly linked library for Linux. It is used to remotely control the Icom IC-R8500 wide band receiver via an RS232 link. All call and return parameters to the control functions are character string based....
20.48 KB  
Programming  -  dotdesktop 0.3
Dotdesktop library provides ability to parse desktop entry file and access the information in a convenient way. Desktop entry file format is defined by freedesktop.org, it is used to describe information about an application such as the name and...
327.68 KB  
Programming  -  Cedalion for Linux 0.2.6
Cedalion is a programming language that allows its users to add new abstractions and define (and use) internal DSLs. Its innovation is in the fact that it uses projectional editing to allow the new abstractions to have no syntactic limitations.
471.04 KB  
Programming  -  libyasl 0.2
Libyasl is a C++ class library to easily realize TCP/UDP/Multicast clientsand servers in IPv4 and IPv6 environments under GNU/Linux systems.
143.36 KB  
Libraries  -  EuGTK 4.8.9
Makes it easy to develop good- looking, fast, cross-platform programs that run on Linux, OS X, and Windows. Euphoria is a very fast interpreted/compiled language with straight-forward syntax. EuGTK allows programming in a clean, object-oriented...
10.68 MB  
Libraries  -  Linux User Group Library Manager 1.0
The LUG Library Manager is a project to help Linux User Groups start their own library. A LUG library is helpful to the community at large because it increases access to information, and gives everyone the opportunity to become more knowledgeable.
5.35 KB  
Libraries  -  Module::MakefilePL::Parse 0.12
Module::MakefilePL::Parse is a Perl module to parse required modules from Makefile.PL. SYNOPSIS use Module::MakefilePL::Parse; open $fh, Makefile.PL; $parser = Module::MakefilePL::Parse->new( join("", ) ); $info = $parser->required;...
8.19 KB  
Libraries  -  sqlpp 0.06
sqlpp Perl package is a SQL preprocessor. sqlpp is a conventional cpp-alike preprocessor taught to understand SQL ( PgSQL, in particular) syntax specificities. In addition to the standard #define/#ifdef/#else/#endif cohort, provides also...
10.24 KB  
Libraries  -  App::SimpleScan::Substitution::Line 2.02
App::SimpleScan::Substitution::Line is a line with optional fixed variable values. SYNOPSIS my $line = App::SimpleScan::Substitution::Line->new(" this "); # Use only this value when substituting " ". $line->fix(substituite =>...
54.27 KB