This is how it looks without the '/' (localhost/index.php): http://postimg.org/image/jxg239qzn/
After adding it at the end of url (localhost/index.php/): http://postimg.org/image/e01pe0isv/
Anyone with experience that could just give a short tip about a probable reason of that.
Here is the index.php :
require_once("php/config.php");
if(substr_count($_SERVER['PHP_SELF'],'/')==1){ // fixing that bug
require_once( ROOT_PATH . "php/header.php" );
if(isvalid(quizzid()) == true){
switch(quizzid()){
case 0:
require_once( ROOT_PATH . "php/questionarios.php" );
break;
default:
require_once( ROOT_PATH . "php/questionario.php" );
break;
}
}
require_once(ROOT_PATH . "php/footer.php"); // footer
}else{ // if there are more than 1 '/' it would redirect to > index
header('Location: /index.php');
}