These four different types of invocation can be categorized into two ways:-
1) Function oriented
2) Object Oriented
Let us first see how to invoke the method grouping standard from a CGI module.
1) Fucntional Oriented Approach
The basic way of including the CGI modeule is
Use CGI;
But to include the standard method grouping, one should use
(a) Use CGI ':standard'; - This means that the standard method grouping is invoked and the methods inside the standard group can be accessed in the program
(b) Use CGI qw(:standard); - here qw() fucntion is used. This is called quote operatot which seperates the individual elements based on white space.
(c) Use CGI qw(/standard/)
2) Object Oriented Approach:
The basic idea of using the object oriented approach is that we can use multiple cgi objects within the script.
Here the approach is
Use CGI;
my $ob = new CGI;
Now one can access the methods of the CGI module using this object $ob
Hope this will help for those who start with perl CGI