0
Мне нужна помощь с моими переписывающими модулями на моей странице. Я хотел бы изменить свой адрес, как я пишу под:Перепишите изменение URL-адреса
http://www.3esdesign.com/portfolio/budynki?projekt=koncepcja-hotelu-roznow
я хочу мою ссылку выглядит
http://www.3esdesign.com/portfolio/budynki/koncepcja-hotelu-roznow
Где «koncepcja-Отел-Rożnów» будет diffrent на другие страницы.
Это мой фактически Htaccess код:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ $1.php [NC,L]
RewriteCond %{HTTP_HOST} ^domena.com(.*) [NC]
RewriteRule ^(.*)$ http://www.domena.com/$1 [R=301,L]
Я пытаюсь этот код в главном каталоге
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^\.]+)$ $1.php [NC,L]
RewriteRule ^portfolio/([\w-]+)/([\w-]+)$ portfolio/$1.php?projekt=$2 [L]
RewriteCond %{HTTP_HOST} ^3esdesign.com(.*) [NC]
RewriteRule ^(.*)$ http://www.3esdesign.com/$1 [R=301,L]
Серуэр журналы:
[Tue Feb 07 11:25:31.379189 2017] [autoindex:error] [pid 55:tid 139960610965248] [client 82.115.92.43:59639] AH01276: Cannot serve directory /home/parkwnetrz/ftp/3esdesign/portfolio/: No matching DirectoryIndex (index.php,index.php4,index.php3,index.php5,index.cgi,index.pl,index.htm,index.html,index.shtm,index.shtml,index.wml,default.htm,default.html,index_default.html,index_default.php) found, and server-generated directory index forbidden by Options directive
[Tue Feb 07 11:16:50.028891 2017] [proxy_fcgi:error] [pid 27:tid 139960527038208] [client 185.85.239.157:58525] AH01071: Got error 'Primary script unknown\n'
[Tue Feb 07 11:13:52.304869 2017] [core:alert] [pid 55:tid 139960594179840] [client 82.115.92.43:59262] /home/parkwnetrz/ftp/3esdesign/.htaccess: Invalid command '^portfolio/([\\w-]+)/([\\w-]+)$', perhaps misspelled or defined by a module not included in the server configuration
[Tue Feb 07 11:13:41.164930 2017] [core:alert] [pid 55:tid 139960602572544] [client 40.77.167.42:17519] /home/parkwnetrz/ftp/3esdesign/.htaccess: Invalid command '^portfolio/([\\w-]+)/([\\w-]+)$', perhaps misspelled or defined by a module not included in the server configuration
[Tue Feb 07 11:13:16.105461 2017] [core:alert] [pid 27:tid 139960476681984] [client 82.115.92.43:59249] /home/parkwnetrz/ftp/3esdesign/.htaccess: Invalid command '^portfolio/([\\w-]+)/([\\w-]+)$', perhaps misspelled or defined by a module not included in the server configuration
[Tue Feb 07 11:13:15.897717 2017] [core:alert] [pid 27:tid 139960485074688] [client 82.115.92.43:59249] /home/parkwnetrz/ftp/3esdesign/.htaccess: Invalid command '^portfolio/([\\w-]+)/([\\w-]+)$', perhaps misspelled or defined by a module not included in the server configuration
[Tue Feb 07 11:13:15.704692 2017] [core:alert] [pid 27:tid 139960527038208] [client 82.115.92.43:59249] /home/parkwnetrz/ftp/3esdesign/.htaccess: Invalid command '^portfolio/([\\w-]+)/([\\w-]+)$', perhaps misspelled or defined by a module not included in the server configuration
[Tue Feb 07 11:13:15.465792 2017] [core:alert] [pid 27:tid 139960535430912] [client 82.115.92.43:59249] /home/parkwnetrz/ftp/3esdesign/.htaccess: Invalid command '^portfolio/([\\w-]+)/([\\w-]+)$', perhaps misspelled or defined by a module not included in the server configuration
[Tue Feb 07 11:13:14.926891 2017] [core:alert] [pid 27:tid 139960569001728] [client 82.115.92.43:59249] /home/parkwnetrz/ftp/3esdesign/.htaccess: Invalid command '^portfolio/([\\w-]+)/([\\w-]+)$', perhaps misspelled or defined by a module not included in the server configuration
[Tue Feb 07 11:05:21.923535 2017] [autoindex:error] [pid 55:tid 139960468289280] [client 82.115.92.43:49537] AH01276: Cannot serve directory /home/parkwnetrz/ftp/3esdesign/portfolio/: No matching DirectoryIndex (index.php,index.php4,index.php3,index.php5,index.cgi,index.pl,index.htm,index.html,index.shtm,index.shtml,index.wml,default.htm,default.html,index_default.html,index_default.php) found, and server-generated directory index forbidden by Options directive
Какая ошибка? и где вы применяете htaccess –
, так что вы используете .htaccess в каталоге portfoilio, я думаю? –
.htaccess находится в главном каталоге, и можно попробовать на моем сервере: [ссылка] (http://www.3esdesign.com/portfolio/budynki?projekt=koncepcja-hotelu-roznow) – Lesiu