The way to include the parameters depends on the method you use to submit a request. Note that in the examples below the names of the parameters are specified directly, which in reality will not work. See the paragraphs on 'How to specify the module and action parameter name' below how to include the parameter names in your request.
action attribute of the <form> element. For example:
<form method="GET"
action="myApp/index.php?module=myModule&
action=doThis">
...
your form fields here
...
</form>
If you are calling the bootstrap script from a link, include the parameters in the URL that you specify in the href attribute of the <a> element. For example:
<a href="myApp/index.php?module=myModule&
action=doThis"/>
<form method="POST" action="myApp/index.php">
<input type="hidden" name="module" value="myModule"/>
<input type="hidden" name="action" value="doThis"/>
...
your other form fields here
...
</form>
_MODULE and _ACTION to include the module and action parameter names in your request, rather than using the string "module" or "action". If you forget to do this, unexpected errors may occur.
The PHP code for this could be something like <?php echo _MODULE ?> and <?php echo _ACTION ?>
In many cases it is also a good idea to use the predefined PHP variable $_SERVER['PHP_SELF'] to identify the bootstrap script.
module and action (as with pre 3.1 versions).
$containerConfig = array(
// Action server configurations
_SERVERS => array(
// Configuration of the (default) action server
'' => array(
// The server's module & action mapping
_SERVER_MAPPING => array(
_MODULE_PARAM => 'theModule'
,_ACTION_PARAM => 'theAction'
)
// The server's initialization parameters
,_INIT_PARAMS => array(
_CONFIGS => array(
'' => '/WEB-INF/conf/default-conf.xml'
,'addon' => '/WEB-INF/conf/addon-conf.xml'
)
,_DIGESTER_CLASS => 'util/xmlConfigDigester'
)
)
...
other container configuration parameters go here
...
);
In this case Phrame will determine the module and action from request parameters theModule and theAction. Note that you still have to use the predefined _MODULE and _ACTION constants to include the names in the request (see before).