I am attempting to pass a variable to a different php file, my code to get the variable is this,
<?php
global $changeDate;
$changeDate = $_POST['editdate'];
$results = "SELECT title, DATE(start) FROM rota WHERE DATE(start) = '$changeDate' ";
$workingUser = mysql_query($results);
include 'phpfunctions/holddate.php';
?>
holddate.php is this,
<?php
$holdingdate = 0;
$holdingdate = $changeDate;
?>
on execution I get an error saying $changeDate
is an undefined variable in holddate.php, where is this going wrong? This includes the global
setting recomended but still recieve same error.