html - PHP $_GET not get value of RewriteRule in case of "index" -


I am having a problem I am trying to get this url:

  MySite.com/index.php?url=category/value1/value2/value3   

From:

  MySite.com/category/value1/ Value2 / value3   

I have this .htaccess file:

  & lt; IfModule mod_rewrite.c & gt; RewriteEngine rewrite %% {REQUEST_FILENAME}! -f rewrite code% {REQUEST_FILENAME}! -d RectitRule ^ (. *) $ Index.php? Url = $ 1 [L, QSA] & lt; / IfModule & gt;   

If everything is "index" then everything is working fine, so if I put urls:

  MySite.com/ Content / tv / color array is equal to $ _GET:  
  array ([url] => content / tv / color /)   

but when I enter:

  MySite.com/index/option1/option2   

The array is empty

  array ()   

I checked my apache.conf file and I do not see the problem.

  & lt; VirtualHost *: 80 & gt; ServerAdmin user@site.com DocumentRoot / home / htdocs & lt; Directory / & gt; Allow all & lt; / Directory & gt; & Lt; Directory / home / htdocs & gt; # & Gt; & Gt; & Gt; & Gt; & Gt; Here's my test app & lt; & Lt; & Lt; & Lt; & Lt; & Lt; & Lt; DirectoryIndex index.html index.php option Allow rewriting on follow-up MultiViews Allow override all orders, deny permission from all & lt; / Directory & gt; Surname / Simplemal / var / SimulationMilp / www ScriptEleas / CGI-bin / USR / Lib / CGI-bin / & lt; Directory "/ usr / lib / cgi-bin" & gt; Allow Override No Option + ExecCGI -MultiViews + SymLinksIfOwnerMatch Order Allow, Allow From All & lt; / Directory & gt; Error log $ {APACHE_LOG_DIR} /error.log # Possible values ​​include: Debug, Notification, Notification, Warning, Error, Alert, # Warning, Rise LogLevel Alert Custom Log $ {APACHE_LOG_DIR} /access.log Combined Surname / Doctor / "/ Usr / share / doc /" directory "/ usr / share / doc /" & gt; Option Index Multiviz follow-of-SIM links of override Do not decline any order, deny all 127.0.0.0/255.0.0.0 :: 1/128 & lt; / Directory & gt; & Lt; / VirtualHost & gt;  

You must close the multiviz option before zero I am not sure why you have changed it clearly. Was it just a config copy-paste?

Also you do not need FollowSymLinks (I'm sure you do not need it) - Turn it off too.

Comments

Popular posts from this blog

excel vba - How to delete Solver(SOLVER.XLAM) code -

github - Teamcity & Git - PR merge builds - anyway to get HEAD commit hash? -

ios - Replace text in UITextView run slowly -