]> Dogcows Code - chaz/p5-CGI-Ex/commitdiff
CGI::Ex 2.32 v2.32
authorPaul Seamons <perl@seamons.com>
Fri, 26 Feb 2010 00:00:00 +0000 (00:00 +0000)
committerCharles McGarvey <chazmcgarvey@brokenzipper.com>
Fri, 9 May 2014 23:46:43 +0000 (17:46 -0600)
20 files changed:
Changes
META.yml
lib/CGI/Ex.pm
lib/CGI/Ex/App.pm
lib/CGI/Ex/Auth.pm
lib/CGI/Ex/Conf.pm
lib/CGI/Ex/Die.pm
lib/CGI/Ex/Dump.pm
lib/CGI/Ex/Fill.pm
lib/CGI/Ex/JSONDump.pm
lib/CGI/Ex/Template.pm
lib/CGI/Ex/Validate.pm
lib/CGI/Ex/Validate.pod
lib/CGI/Ex/validate.js
samples/app/app1/lib/App1.pm
samples/app/app1/lib/App1/DoBill.pm
samples/app/app1/lib/App1/PickDomain.pm
samples/app/app1/lib/App1/Thankyou.pm
t/1_validate_03_cgi.t
t/2_fill_10_escape.t

diff --git a/Changes b/Changes
index a14d5fc808354c86db652bd1edd4f6c5e924f9d8..708f5ff1df48fa507b5691c7e5e852fecbf8c998 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,3 +1,15 @@
+2.32
+    2010-02-25
+        * (Validate) Allow for default to be an arrayref
+
+2.31
+    2010-02-24
+        * (Auth) allow for secure flag via cookie_secure
+        * Allow validate.js to use change and blur on individual elements
+        * Allow validate.js to not strip trailing whitespace on change
+        * (Validate) Allow more items in local parts
+        * (Ex) Make sure make_form doesn't die on non-arrayref keys
+
 2.27
     2008-09-15
         * (App) Fix morph history during errors or other direct morph calls
index f010773b3494ffb3b53fb46496d7562f3ba0eb22..7216ca2cc45c9a4df6f602daf670adbdbd79ebe6 100644 (file)
--- a/META.yml
+++ b/META.yml
@@ -1,11 +1,14 @@
-# http://module-build.sourceforge.net/META-spec.html
-#XXXXXXX This is a prototype!!!  It will change in the future!!! XXXXX#
-name:         CGI-Ex
-version:      2.27
-version_from: lib/CGI/Ex.pm
-installdirs:  site
-requires:
+--- #YAML:1.0
+name:                CGI-Ex
+version:             2.32
+abstract:            CGI utility suite - makes powerful application writing fun and easy
+license:             ~
+author:              
+    - Paul Seamons
+generated_by:        ExtUtils::MakeMaker version 6.42
+distribution_type:   module
+requires:     
     Template::Alloy:               1.004
-
-distribution_type: module
-generated_by: ExtUtils::MakeMaker version 6.30_01
+meta-spec:
+    url:     http://module-build.sourceforge.net/META-spec-v1.3.html
+    version: 1.3
index 09e5139d26ac82b9fdd7b868506ed31ff7980a03..fa8d1fe3a431eb84f069659c900f9e2fb499cb44 100644 (file)
@@ -24,7 +24,7 @@ use vars qw($VERSION
 use base qw(Exporter);
 
 BEGIN {
-    $VERSION               = '2.27';
+    $VERSION               = '2.32';
     $PREFERRED_CGI_MODULE  ||= 'CGI';
     @EXPORT = ();
     @EXPORT_OK = qw(get_form
@@ -163,7 +163,7 @@ sub make_form {
         my $val = $form->{$key};
         $key =~ s/([^\w.\-\ ])/sprintf('%%%02X', ord $1)/eg;
         $key =~ y/ /+/;
-        foreach (ref($val) ? @$val : $val) {
+        foreach (ref($val) eq 'ARRAY' ? @$val : $val) {
             my $_val = $_; # make a copy
             $_val =~ s/([^\w.\-\ ])/sprintf('%%%02X', ord $1)/eg;
             $_val =~ y/ /+/;
index 305fa2325e94fd2b9d909e542140ca5523145083..79720fc4f9c9eef62ce785909fb498ae06d00c83 100644 (file)
@@ -11,7 +11,7 @@ BEGIN {
     eval { use Time::HiRes qw(time) };
     eval { use Scalar::Util };
 }
-our $VERSION = '2.27';
+our $VERSION = '2.32';
 
 sub new {
     my $class = shift || croak "Usage: ".__PACKAGE__."->new";
@@ -691,17 +691,18 @@ sub finalize  { 1 } # false means show step
 sub hash_base {
     my ($self, $step) = @_;
 
-    return $self->{'hash_base'} ||= do {
-        my $copy = $self;  eval { require Scalar::Util; Scalar::Util::weaken($copy) };
-        my $hash = {
-            script_name     => $self->script_name,
-            path_info       => $self->path_info,
-            js_validation   => sub { $copy->run_hook('js_validation', $step, shift) },
-            generate_form   => sub { $copy->run_hook('generate_form', $step, (ref($_[0]) ? (undef, shift) : shift)) },
-            form_name       => $self->run_hook('form_name', $step),
-            $self->step_key => $step,
-        };
+    my $hash = $self->{'hash_base'} ||= {
+        script_name => $self->script_name,
+        path_info   => $self->path_info,
     };
+
+    my $copy = $self;  eval { require Scalar::Util; Scalar::Util::weaken($copy) };
+    $hash->{'js_validation'} = sub { $copy->run_hook('js_validation', $step, shift) };
+    $hash->{'generate_form'} = sub { $copy->run_hook('generate_form', $step, (ref($_[0]) ? (undef, shift) : shift)) };
+    $hash->{'form_name'}     = $self->run_hook('form_name', $step);
+    $hash->{$self->step_key} = $step;
+
+    return $hash;
 }
 
 sub hash_common { $_[0]->{'hash_common'} ||= {} }
index 9abb8317a5aa017d931597faff626fa707d4273d..149123e13b6ecc7227d65c1f7ab72aba1c1eff24 100644 (file)
@@ -19,7 +19,7 @@ use Digest::MD5 qw(md5_hex);
 use CGI::Ex;
 use Carp qw(croak);
 
-$VERSION = '2.27';
+$VERSION = '2.32';
 
 ###----------------------------------------------------------------###
 
@@ -269,11 +269,13 @@ sub set_cookie {
     my $key  = $args->{'name'};
     my $val  = $args->{'value'};
     my $dom  = $args->{'domain'} || $self->cookie_domain;
+    my $sec  = $args->{'secure'} || $self->cookie_secure;
     $self->cgix->set_cookie({
         -name    => $key,
         -value   => $val,
         -path    => $args->{'path'} || $self->cookie_path($key, $val) || '/',
         ($dom ? (-domain => $dom) : ()),
+        ($sec ? (-secure => $sec) : ()),
         ($args->{'expires'} ? (-expires => $args->{'expires'}): ()),
     });
     $self->cookies->{$key} = $val;
@@ -311,8 +313,10 @@ sub expires_min      { my $s = shift; $s->{'expires_min'} = 6 * 60 if ! defined
 sub failed_sleep     { shift->{'failed_sleep'}     ||= 0              }
 sub cookie_path      { shift->{'cookie_path'}      }
 sub cookie_domain    { shift->{'cookie_domain'}    }
+sub cookie_secure    { shift->{'cookie_secure'}    }
 sub use_session_cookie { shift->{'use_session_cookie'} }
 sub disable_simple_cram { shift->{'disable_simple_cram'} }
+sub complex_plaintext { shift->{'complex_plaintext'} }
 
 sub logout_redirect {
     my ($self, $user) = @_;
@@ -509,7 +513,18 @@ sub parse_token {
             : ($armor eq 'base64')          ? eval { local $^W; decode_base64($token) }
             : ($bkey = $self->use_blowfish) ? decrypt_blowfish($token, $bkey)
             : next;
-        if ($copy =~ m|^ ([^/]+) / (\d+) / (-?\d+) / (.*) / ([a-fA-F0-9]{32}) (?: / (sh\.\d+\.\d+))? $|x) {
+        if ($self->complex_plaintext && $copy =~ m|^ ([^/]+) / (\d+) / (-?\d+) / ([^/]*) / (.*) $|x) {
+            $data->add_data({
+                user         => $1,
+                plain_time   => $2,
+                expires_min  => $3,
+                payload      => $4,
+                test_pass    => $5,
+                armor        => $armor,
+            });
+            $found = 1;
+            last;
+        } elsif ($copy =~ m|^ ([^/]+) / (\d+) / (-?\d+) / ([^/]*) / ([a-fA-F0-9]{32}) (?: / (sh\.\d+\.\d+))? $|x) {
             $data->add_data({
                 user         => $1,
                 cram_time    => $2,
@@ -551,7 +566,7 @@ sub verify_password {
         } else {
             my $rand1 = $1;
             my $rand2 = $2;
-            my $real  = $pass =~ /^[a-f0-9]{32}$/ ? lc($pass) : md5_hex($pass);
+            my $real  = $pass =~ /^[a-fA-F0-9]{32}$/ ? lc($pass) : md5_hex($pass);
             my $str  = join("/", @{$data}{qw(user cram_time expires_min payload)});
             my $sum = md5_hex($str .'/'. $real .('/sh.'.$array->[$rand1].'.'.$rand2));
             if ($data->{'expires_min'} > 0
@@ -566,7 +581,7 @@ sub verify_password {
     } elsif ($data->{'cram_time'}) {
         $data->add_data(type => 'simple_cram');
         die "Type simple_cram disabled during verify_password" if $self->disable_simple_cram;
-        my $real = $pass =~ /^[a-f0-9]{32}$/ ? lc($pass) : md5_hex($pass);
+        my $real = $pass =~ /^[a-fA-F0-9]{32}$/ ? lc($pass) : md5_hex($pass);
         my $str  = join("/", @{$data}{qw(user cram_time expires_min payload)});
         my $sum  = md5_hex($str .'/'. $real);
         if ($data->{'expires_min'} > 0
@@ -576,6 +591,12 @@ sub verify_password {
             $err = 'Invalid login';
         }
 
+    ### expiring plain
+    } elsif ($data->{'plain_time'}
+             && $data->{'expires_min'} > 0
+             && ($self->server_time - $data->{'plain_time'}) > $data->{'expires_min'} * 60) {
+        $err = 'Login expired';
+
     ### plaintext_crypt
     } elsif ($pass =~ m|^([./0-9A-Za-z]{2})([./0-9A-Za-z]{11})$|
              && crypt($data->{'test_pass'}, $1) eq $pass) {
@@ -584,12 +605,12 @@ sub verify_password {
     ### failed plaintext crypt
     } elsif ($self->use_crypt) {
         $err = 'Invalid login';
-        $data->add_data(type => 'crypt', was_plaintext => ($data->{'test_pass'} =~ /^[a-f0-9]{32}$/ ? 0 : 1));
+        $data->add_data(type => 'crypt', was_plaintext => ($data->{'test_pass'} =~ /^[a-fA-F0-9]{32}$/ ? 0 : 1));
 
     ### plaintext and md5
     } else {
-        my $is_md5_t = $data->{'test_pass'} =~ /^[a-f0-9]{32}$/;
-        my $is_md5_r = $pass =~ /^[a-f0-9]{32}$/;
+        my $is_md5_t = $data->{'test_pass'} =~ /^[a-fA-F0-9]{32}$/;
+        my $is_md5_r = $pass =~ /^[a-fA-F0-9]{32}$/;
         my $test = $is_md5_t ? lc($data->{'test_pass'}) : md5_hex($data->{'test_pass'});
         my $real = $is_md5_r ? lc($pass) : md5_hex($pass);
         $data->add_data(type => ($is_md5_r ? 'md5' : 'plaintext'), was_plaintext => ($is_md5_t ? 0 : 1));
@@ -609,24 +630,24 @@ sub generate_token {
     die "Can't generate a token off of a failed auth" if ! $data;
     die "Can't generate a token for a user which contains a \"/\"" if $data->{'user'} =~ m{/};
     my $token;
+    my $exp = defined($data->{'expires_min'}) ? $data->{'expires_min'} : $self->expires_min;
+
+    my $user = $data->{'user'} || die "Missing user";
+    my $load = $self->generate_payload($data);
+    die "User can not contain a \"/\."                                           if $user =~ m|/|;
+    die "Payload can not contain a \"/\.  Please encode it in generate_payload." if $load =~ m|/|;
 
     ### do kinds that require staying plaintext
     if (   (defined($data->{'use_plaintext'}) ?  $data->{'use_plaintext'} : $self->use_plaintext) # ->use_plaintext is true if ->use_crypt is
         || (defined($data->{'use_crypt'})     && $data->{'use_crypt'})
         || (defined($data->{'type'})          && $data->{'type'} eq 'crypt')) {
         my $pass = defined($data->{'test_pass'}) ? $data->{'test_pass'} : $data->{'real_pass'};
-        $token = $data->{'user'} .'/'. $pass;
+        $token = $self->complex_plaintext ? join('/', $user, $self->server_time, $exp, $load, $pass) : "$user/$pass";
 
     ### all other types go to cram - secure_hash_cram, simple_cram, plaintext and md5
     } else {
-        my $user = $data->{'user'} || die "Missing user";
-        my $real = defined($data->{'real_pass'})   ? ($data->{'real_pass'} =~ /^[a-f0-9]{32}$/ ? lc($data->{'real_pass'}) : md5_hex($data->{'real_pass'}))
-                                                   : die "Missing real_pass";
-        my $exp  = defined($data->{'expires_min'}) ? $data->{'expires_min'} : $self->expires_min;
-        my $load = $self->generate_payload($data);
-        die "Payload can not contain a \"/\.  Please escape it in generate_payload." if $load =~ m|/|;
-        die "User can not contain a \"/\."                                           if $user =~ m|/|;
-
+        my $real = defined($data->{'real_pass'}) ? ($data->{'real_pass'} =~ /^[a-fA-F0-9]{32}$/ ? lc($data->{'real_pass'}) : md5_hex($data->{'real_pass'}))
+                                                 : die "Missing real_pass";
         my $array;
         if (! $data->{'prefer_simple_cram'}
             && ($array = eval { $self->secure_hash_keys })
@@ -948,6 +969,7 @@ described separately.
     cgix
     cleanup_user
     cookie_domain
+    cookie_secure
     cookie_path
     cookies
     expires_min
index 0fd0199bdc41cb9a34c7ba12f0ce5084a51127e8..04ff2a33ce71b7b413dbfa71af12bdc33a1be5ed 100644 (file)
@@ -29,7 +29,7 @@ use vars qw($VERSION
             );
 @EXPORT_OK = qw(conf_read conf_write in_cache);
 
-$VERSION = '2.27';
+$VERSION = '2.32';
 
 $DEFAULT_EXT = 'conf';
 
index c3ef904026960aee069c13c0a268c52e8994d324..50aa0fdb924997479a30c38e12084b8a7f0176a2 100644 (file)
@@ -23,7 +23,7 @@ use CGI::Ex;
 use CGI::Ex::Dump qw(debug ctrace dex_html);
 
 BEGIN {
-  $VERSION = '2.27';
+  $VERSION = '2.32';
   $SHOW_TRACE = 0      if ! defined $SHOW_TRACE;
   $IGNORE_EVAL = 0     if ! defined $IGNORE_EVAL;
   $EXTENDED_ERRORS = 1 if ! defined $EXTENDED_ERRORS;
index 1ccf5071597a4f21273fdcbcc9b298b2817994c6..924d493402f7dfc8ad8a988a044e56fe223e5d90 100644 (file)
@@ -17,7 +17,7 @@ use vars qw(@ISA @EXPORT @EXPORT_OK $VERSION
 use strict;
 use Exporter;
 
-$VERSION   = '2.27';
+$VERSION   = '2.32';
 @ISA       = qw(Exporter);
 @EXPORT    = qw(dex dex_warn dex_text dex_html ctrace dex_trace);
 @EXPORT_OK = qw(dex dex_warn dex_text dex_html ctrace dex_trace debug);
index 2eaffa4b23994012ef82b9a090de9a11cab5973f..1183950aba3146143fd095a4a6e7bb700d484093 100644 (file)
@@ -24,7 +24,7 @@ use vars qw($VERSION
 use base qw(Exporter);
 
 BEGIN {
-    $VERSION   = '2.27';
+    $VERSION   = '2.32';
     @EXPORT    = qw(form_fill);
     @EXPORT_OK = qw(fill form_fill html_escape get_tagval_by_key swap_tagval_by_key);
 };
index 07ce9e99996e2f93e3ff82af7ad20a233440c70a..b45b11bd67b1ae1ceee203ac4a381a06219ed770 100644 (file)
@@ -17,7 +17,7 @@ use strict;
 use base qw(Exporter);
 
 BEGIN {
-    $VERSION  = '2.27';
+    $VERSION  = '2.32';
 
     @EXPORT = qw(JSONDump);
     @EXPORT_OK = @EXPORT;
index b92ec92881149c1ad7cd55f499ad54ae1841f36f..1cd650a931f89fbb73fba45cb8cf529f56b18fe6 100644 (file)
@@ -25,7 +25,7 @@ use vars qw($VERSION
             $VOBJS
             );
 
-$VERSION = '2.27';
+$VERSION = '2.32';
 
 ### install true symbol table aliases that can be localized
 *QR_PRIVATE        = *Template::Alloy::QR_PRIVATE;
index 184327b174bad97294c055a69372a0ef578c745a..d2717ccdc2fc281aa86b7d7c35c6fe9cb729fd6b 100644 (file)
@@ -8,7 +8,7 @@ package CGI::Ex::Validate;
 use strict;
 use Carp qw(croak);
 
-our $VERSION  = '2.27';
+our $VERSION  = '2.32';
 our $QR_EXTRA = qr/^(\w+_error|as_(array|string|hash)_\w+|no_\w+)/;
 our @UNSUPPORTED_BROWSERS = (qr/MSIE\s+5.0\d/i);
 our $JS_URI_PATH;
@@ -237,16 +237,16 @@ sub validate_buddy {
     if ($field_val->{'had_error'}   && ! $self->{'had_error'}->{$field})   { return [[$field, 'had_error',   $field_val, $ifs_match]]; }
     if ($field_val->{'was_checked'} && ! $self->{'was_checked'}->{$field}) { return [[$field, 'was_checked', $field_val, $ifs_match]]; }
 
-    my $values   = UNIVERSAL::isa($form->{$field},'ARRAY') ? $form->{$field} : [$form->{$field}];
-    my $n_values = @$values;
-
     # allow for default value
-    if (exists $field_val->{'default'}) {
-        if ($n_values == 0 || ($n_values == 1 && (! defined($values->[0]) || ! length($values->[0])))) {
-            $form->{$field} = $values->[0] = $field_val->{'default'};
-        }
+    if (defined($field_val->{'default'})
+        && (!defined($form->{$field})
+            || (UNIVERSAL::isa($form->{$field},'ARRAY') ? !@{ $form->{$field} } : !length($form->{$field})))) {
+        $form->{$field} = $field_val->{'default'};
     }
 
+    my $values   = UNIVERSAL::isa($form->{$field},'ARRAY') ? $form->{$field} : [$form->{$field}];
+    my $n_values = @$values;
+
     # allow for a few form modifiers
     my $modified = 0;
     foreach my $value (@$values) {
@@ -564,10 +564,8 @@ sub check_type {
     # the "username" portion of an email address - sort of arbitrary
     } elsif ($type eq 'local_part') {
         return 0 if ! defined($value) || ! length($value);
-        return 0 if $value =~ m/[^A-Za-z0-9_.\-\^=?\#!&+]/
-            || $value =~ m/^[\.\-]/
-            || $value =~ m/[\.\-\&]$/
-            || $value =~ m/(\.\-|\-\.|\.\.)/;
+        # ignoring all valid quoted string local parts
+        return 0 if $value =~ m/[^\w.~!\#\$%\^&*\-=+?]/;
 
     # standard IP address
     } elsif ($type eq 'ip') {
index b7bce1940151a82f2a7e1999616b56a1257d075f..9311c05c41ceb24d4473e28d963316867588622b 100644 (file)
@@ -444,7 +444,7 @@ be concatenated with ||.  Available in JS.
     {
         field   => 'my_ip',
         match   => 'm/^\d{1,3}(\.\d{1,3})3$/',
-        match_2 => '!/^0\./ || !/^192\./',
+        match_2 => '!m/^0\./ || !m/^192\./',
     }
 
 =item C<max_in_set> and C<min_in_set>
index 388f6739d8277700c5752e80fe700d836619dc92..7b469115ba07c99fc76b2498ccf5f64454201544 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright 2008 - Paul Seamons - $Revision: 1.81 $
+// Copyright 2008 - Paul Seamons - $Revision: 1.18 $
 // Distributed under the Perl Artistic License without warranty
 // See perldoc CGI::Ex::Validate for usage
 
@@ -310,7 +310,10 @@ function v_validate_buddy (form, field, field_val, val_hash, ifs_match) {
  for (var i = 0; i < values.length; i++) {
   if (typeof(values[i]) == 'undefined') continue;
   var orig = values[i];
-  if (! field_val.do_not_trim)      values[i] = values[i].replace(/^\s+/,'').replace(/\s+$/,'');
+  if (! field_val.do_not_trim) {
+    values[i] = values[i].replace(/^\s+/,'');
+    if (v_event != 'change') values[i] = values[i].replace(/\s+$/,'');
+  }
   if (field_val.trim_control_chars) values[i] = values[i].replace(/\t/g,' ').replace(/[\x00-\x1F]/g,'');
   if (field_val.to_upper_case) values[i] = values[i].toUpperCase();
   if (field_val.to_lower_case) values[i] = values[i].toLowerCase();
@@ -509,10 +512,8 @@ function v_check_type (value, type, field, form) {
  } else if (type == 'LOCAL_PART') {
   if (typeof(value) == 'undefined' || ! value.length) return 0;
   if (typeof(v_local_part) != 'undefined') return (value.match(v_local_part) ? 1 : 0);
-  if (value.match(/[^a-z0-9.\-!&+]/)) return 0;
-  if (value.match(/^[.\-]/))          return 0;
-  if (value.match(/[.\-&]$/))         return 0;
-  if (value.match(/(\.-|-\.|\.\.)/))  return 0;
+  // ignoring all valid quoted string local parts
+  if (value.match(/[^\w.~!\#\$%\^&*\-=+?]/)) return 0;
 
  } else if (type == 'IP') {
   if (! value) return 0;
@@ -832,7 +833,7 @@ document.validate = function (form, val_hash) {
  }
 
  var f = val_hash['group set_all_hook'] || document.validate_set_all_hook;
- if (f) f(err_obj);
+ if (f) f(err_obj, val_hash, form);
 
  var field = err_obj.first_field();
  if (field && form[field]) {
@@ -948,7 +949,9 @@ document.check_form = function (form, val_hash) {
    if (k == 'extend') continue; // Protoype Array()
    var el = form[k];
    if (! el) return v_error("No form element by the name "+k);
-   v_el_attach(el, h[k], form, val_hash);
+   var _change = !types.change ? 0 : typeof(types.change) == 'object' ? types.change[k] : 1;
+   var _blur   = !types.blur   ? 0 : typeof(types.blur)   == 'object' ? types.blur[k]   : 1;
+   v_el_attach(el, h[k], form, val_hash, _change, _blur);
   }
  }
 
@@ -960,9 +963,10 @@ document.check_form = function (form, val_hash) {
  if (types.load) { v_event = 'load'; document.validate(form) }
 }
 
-function v_el_attach (el, fvs, form, val_hash) {
+function v_el_attach (el, fvs, form, val_hash, _change, _blur) {
+ if (!_change && !_blur) return;
  if (! el.type) {
-  if (el.length) for (var i = 0; i < el.length; i++) v_el_attach(el[i], fvs, form, val_hash);
+  if (el.length) for (var i = 0; i < el.length; i++) v_el_attach(el[i], fvs, form, val_hash, _change, _blur);
   return;
  }
  var types = val_hash['group onevent'];
@@ -997,8 +1001,8 @@ function v_el_attach (el, fvs, form, val_hash) {
    v_inline_error_set(k, e[k], val_hash, form);
   }
  };
- if (types.blur) el.onblur = func;
- if (types.change && ! (''+el).match(/HTMLCollection/)) { // find better way on opera
+ if (_blur) el.onblur = func;
+ if (_change && ! (''+el).match(/HTMLCollection/)) { // find better way on opera
   var type = el.type ? el.type.toLowerCase() : '';
   if (type.match(/(password|text|textarea)/)) el.onkeyup = func;
   else if (type.match(/(checkbox|radio)/)) el.onclick = func;
index a86c1a00f2a46588660099821e4d01b0b3eaf47d..b9eafbe5ba61b2fd32a5d4ac9e0c834a951e9e4b 100644 (file)
@@ -26,11 +26,11 @@ sub post_navigate {
 
 ###----------------------------------------------------------------###
 
-sub load_conf       { 1 } # let configuration be read from a file
+sub load_conf       { 1 }
 sub conf_file       { "$Bin/app1.yaml" }
 sub conf_validation { {path => {required => 1, max_values => 100}} }
 
-sub allow_morph     { 1 } # allow each step to be in a separate file
+sub allow_morph     { 1 }
 
 sub name_module     { "" } # allow content files to be in /tt/ directory directly
 sub template_path   { "$Bin/tt" }
index e759e918ac0490eabc4dd4b4f7c7b5e4a6ecc206..3f7867abc224ee36db52855af972228fbf4d222e 100644 (file)
@@ -2,7 +2,7 @@ package App1::DoBill;
 
 =head1 NAME
 
-App1::DoBill - This step would process the billing
+App1::DoBill - handle this step of the App1 app
 
 =cut
 
index e106b5392ceea39945e5c7d16b202287de80b18d..cd9a31539a0ee1d5e013678d139f477599da0df3 100644 (file)
@@ -2,7 +2,7 @@ package App1::PickDomain;
 
 =head1 NAME
 
-App1::PickDomain - usually the first step - pick a domain
+App1::PickDomain - handle this step of the App1 app
 
 =cut
 
index e88e8b81c74fa3fd967f0e95e08573c7159fe6bc..353e9aef8dce7b5a9966c4e96d0997d3eac95c10 100644 (file)
@@ -2,7 +2,7 @@ package App1::Thankyou;
 
 =head1 NAME
 
-App1::Thankyou - show the final page of the application
+App1::Thankyou - handle this step of the App1 app
 
 =cut
 
index a6e41531be6c5116c545c878a68e00066438642c..ef75ee3f7aa12701bba2556156735433ab7c321f 100644 (file)
@@ -2,7 +2,7 @@
 
 =head1 NAME
 
-1_validate_03_cgi.t - Test CGI::Ex::Validate's ability to interact with CGI.pm.
+1_validate_03_cgi.t - Test CGI::Ex::Fill's ability to interact with CGI.pm.
 
 =cut
 
index e32fc9fd934e32803fe10349bd22dc91702be8ce..538a31b3194101ca8c746a77772bcaf96411b1de 100644 (file)
@@ -43,4 +43,4 @@ my $strings_output = join("\n", sort split(/[\s><]+/, lc($output)));
 my $strings_html = join("\n", sort split(/[\s><]+/, lc($html)));
 
 ok($strings_output eq $strings_html,
-   "Strings matched");
+   "Strings matched ($strings_output)");
This page took 0.044187 seconds and 4 git commands to generate.