modified Ib3 Controller.php