Kohana URLs, including index for redirect and pagination

I am having a problem with the KO3 core inserting index.php into my URL when I use redirect
Request :: instance () → redirects ('something'); or $ paginationStuffHere-> render ().

The result of any of these is http://www.something.com/ index.php / something

This is not a problem when I use the full URL for redirection instead of relatives, such as Request :: instance () -> redirect ('http://www.something.com/something'); but there really is no way to do this using the pagination functions ... that I found, so I really need to find where it adds this index.php

This does not happen when I use View :: factory ('something / something') → render (); this is the only thing I could find people having similar problems with

Base URL set to '/' in bootstrap.php

My .htaccess looks like this

RewriteEngine On RewriteBase / RewriteRule ^(application|modules|system) -[F,L] RewriteCond %(REQUEST_FILENAME) !-f RewriteCond %(REQUEST_FILENAME) !-d RewriteRule .* index.php/$0 [PT,L] 

Thanks in advance for any suggestions.

+4
source share
1 answer

Find Kohana :: init () in your bootstrap.php and set index_file to FALSE in this array

+15
source

Source: https://habr.com/ru/post/1341546/


All Articles