pkit_get_default_page — Returns "index" page when no page_id is specified.
sub pkit_get_default_page {
my ($model) = @_;
if($model->pnotes('user_id')){
# user is logged in, go to account page
return 'myaccount';
} else {
# user not logged in, go to main page
return 'index';
}
}
If no page is specified, then this subroutine will return the page_id of the page that should be displayed. You only have to provide this routine if you wish to override the default method, which simply returns the default_page attribute as listed in the Config/Config.xml file.