The redirect is working and the section where the template is to be included is entered but it's still showing the previous template. It's almost like
the include is getting ignored.
Sample code:
Code: Select all
$update = $db->create_update("prescriptions", $_POST, null, "id =". $_POST['prescription_id']);
if($update){ header("Location: prescription.php?step=1"); exit; }
include_once(BASE_PATH ."/templates/cpanel/prescription.tmpl.html");
and here's the code in the prescription.tmpl.html template:
Code: Select all
<body leftmargin="10" topmargin="10" marginwidth="10" marginheight="10">
<?php if($step == 1){ echo "INCLUDING TEMPLATE 1 HERE"; include(BASE_PATH ."/templates/cpanel/prescription_1.tmpl.html"); } ?>
<?php if($step == 2){ include(BASE_PATH ."/templates/cpanel/prescription_2.tmpl.html"); } ?>
</body>
</html>
Very strange - any ideas?
Thanks,
Clem C