Hi friends, Good day. I am having the following code snippet in init.php.
<?php
include_once("config.php");
include_once(__SITE_PATH . 'view/' . $_REQUEST['page'] . EXT);
$loginobj = new $_REQUEST['page']($_REQUEST['billingentitynuber']);
$text = $loginobj->$_REQUEST['content']();
echo $text;
?>
In Jquery I am having the function Jquery_event.js
$("#entertoapp").click(function()
{
alert($("#btval").val());
$.ajax({
type: "POST",
url: "init.php?page=processing&content=enterintoapplication&btval=" + $("#btval").val(),
success: function(msg) {
alert(msg);
if(msg==1)
window.location.href='index.php?page=processing&content=mycontent';
}
});
});
In processing.php I am having
<?php
class processing
{
public function enterintoapplication()
{
global $billingentityname;
$_SESSION['btval'] = $billingentityname;
echo $billingentityname;
}
}
?>
My problem is I am getting all the parameters in the init.php. But when I call a function I need to get in the processing.php in the enterintoapplication function (i.e. I am expecting btval
in the enterintoapplication
function). How can I achieve this? I tried to get $_REQUEST['btval']
within the function. But I didn't get.