php


Mod rewrite localhost working fine, on server in PHP QUERY_STRING and $_GET empty


I have a weird problem. I develop my sites on localhost and after that i distribute it server side. Most of the time this is working as expected but now notice something weird and cannot figure out what the problem is.
On the server all RewriteRule redirects but without expected queries. Something like this is working fine on localhost but not on the server:
RewriteEngine On
....
....
RewriteRule .....
EDIT: Changed entries for security reasons, sorry!
....
....
Does anybody knows what is going on? Do i miss something? Why are the queries not passed thru? Is it a server configuration? Cannot find anything about it on the internet.
Thank you for your comments.
EDIT: SOLUTION below, second comment. Has something to do with what apache handles first.
These things are nearly impossible to debug. But mod_rewrite offers one feature that you should set up to investigate this:
RewriteLog /tmp/rewritelog.txt
RewriteLogLevel 2
The RewriteLog directive however cannot be used from .htaccess. You need to declare it in the vhost or main server configuration. If level 2 is still insufficient, then try 3.
Otherwise I'd just would advise you to try a RewriteBase, since you seem to match varying directory levels with your rules. Possibly repeat your rules in the subdirectories (streambutler/) again. Apaches mod_rewrite is peculiar and ignores them in the parent dir sometimes.
#Erwinus, the "Perdir" functionality that you discuss is standard in Apache but not well understood. Apache will probe for, then open and read all existing .htaccess files on the path to a script filename. (Ignoring the RewriteOptions inherit chase which is rarely chosen) it uses the deepest .htaccess file that it finds that has RewriteEngine On.
I would therefore differ from Mario's view in that IMHO its almost impossible to get a parent directories rewrite rules to preempt a child directory set -- the default action of Apache is to ignore the parent. I explain in a more detail in this blog article.

Related Links

Displaying nothing when I am trying to scrape data using simple html dom parser
PHP inserting late through time blocks
YII Server Move. Internal Server Error. CDbException
Having troubles posting form data with ajax to controller action (laravel)
Laravel 5.2 Unit Tests error: BadMethodCallException: Call to undefined method Illuminate\Database\Query\Builder::make()
Full-Text Search Function not working at all
WordPress settings page for custom methods
laravel get jobs from redis queue located in another codebase\project?
How to concatenate variable and string that contains () in php
Laravel mysql multiple operations with one DB instance
How to add form data to a bootstrap modal in the same page by using jQuery?
WP - How to get all the comment_post_ID in bulk comment approval
How to grab a random MYSQL Column Value using PHP and echo it?
Secure way to allow a specific PHP script to read/write a directory?
php searching empty fields in the db [duplicate]
PHP strtotime returns incorrect month [duplicate]

Categories

HOME
rust
blast
mpdf
yii
softlayer
tcsh
loopbackjs
plpgsql
malware
mirc
moodle-api
navigation
ipv6
mithril.js
u-boot
kurento
mailing-list
hdl
neo4j.rb
kamailio
conda
strophe.js
clipboard
gravity-forms-plugin
acrobat
ninject
locks
steam-web-api
android-collapsingtoolbar
kendo-listview
xmlunit
counting
des
landscape
assertions
pdfnet
bluemixtools
android-alarms
python-jira
plane
dbcc
jqgrid-asp.net
doctrine-extensions
flume-twitter
linq-to-excel
beeline
subforms
simple-schema
line-intersection
connect-direct
mechanicalturk
sidewaffle
perl-data-structures
libharu
perforce-integrate
ajaxmin
rails-engines
maximize
distributed-cache
accessibilityservice
seadragon
wikimedia-commons
odesk
deeplink
dsa
swagger-maven-plugin
whitespace-language
wicket-1.5
git-reset
redpitaya
jomsocial
jmenubar
compiler-flags
virtual-channel
lru
hints
microformats
towers-of-hanoi
chronometer
type-safety
qtextbrowser
motodev-studio
net-use
page-curl
webresponse
mygeneration
fuzzy-comparison
index.dat
server-load
chronic

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App