Code-style refactoring.
Improved work with index.php and refactoring from htaccess.