AJAX, PHP and empty variables
Hi all,
I'm using two different hosting for developing an AJAX based application.
The first hostng is at my home (for develoment), the second one is provided from a paid hosting service (for production).
My problem is that in the production hosting I can't see the value of the variables I send via AJAX.
There is the code:
- $.get("AJAXChangeOrderStatus.php", { orderid: order, newstatus: 1 }, function(data) {
- ...
And in the AJAXChangeOrderStatus.php i get the values in this way:
- <?php
- include_once '../includes/dbconfig.php';
- $orderid = $_GET['oredrid'];
- $newstatus = $_GET['newstatus'];
$orderid and $newstatus are empty, because $_GET['oredrid'] and $_GET['newstatus'] are empty.
Where I'm doing mistakes?