On Apr 29, 2006, at 1:31 PM, Cees Hek wrote:

On 4/29/06, Ed Pigg <[EMAIL PROTECTED]> wrote:
I've split my application run modes into several modules and a base
class.

package myapp::Base;

use strict;
use warnings;
use CGI::Application::Plugin::Session;
use CGI::Application::Plugin::Authentication;
use base 'CGI::Application';

sub common_function {
}


I made a change to the base package

use base 'CGI::Application';
use CGI::Application::Plugin::Session;
use CGI::Application::Plugin::Authentication;

Should the order of 'use' statements make a difference here?


package myapp::somestuff;
use strict;
use warnings;
use base 'myapp::Base';

my somestuff_function {
        my $self = shift;
        my $value = $self->common_function();    -----> error
common_function not found
}

Changes to the derived package adding
use base 'myapp::Base';

__PACKAGE__->authen->protected_runmodes(':all');
.....
added the login run_mode from the base class and now I am getting the login run_mode when attempting to access the derived class without logging in. I have not tested other calls. I'm still working on the authentication aspect.

Ed Pigg

---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/[email protected]/
             http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to