die("Must be done over a POST request, sorry"); } } function view_session() { var_dump($_SESSION); } function download() { header("Pragma: public"); // required header("Expires: 0"); header("Cache-Control: must-revalidate, post-check=0, pre-check=0"); header("Cache-Control: private", false); // required for certain browsers header("Content-Type: application/fluidia"); header("Content-Disposition: attachment; filename=\"fluidia-save.fld\";"); header("Content-Transfer-Encoding: binary"); //ob_start(); echo contents, then header content-length //header("Content-Length: " . filesize($parsed_url['localpath'])); $key = count($_SESSION['fluidia_object']) - 1; var_dump($_SESSION['fluidia_object'][$key]); exit; } } $main = new main(); // First things first, what controller function are we running on this call? $main->parse_controller(); // Run $main->go(); //var_dump($main);