@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4



Comments:

<0> never used lsof before
<1> dubTV: did you turn on rewrites? are you allowed to use rewrites where you tried to use them?
<2> twkm: yes, i've uncommented mod_write from modules list in httpd.conf
<2> i'm using my local test server: apache2.0
<1> mod_write -- what's that?
<3> it's kewl
<2> mod_rewrite i mean
<1> dubTV: and did you put the rewrite in an access file?
<2> twkm: yes
<3> AllowOverride is On?
<2> now i got a Bad Request
<4> read error_log, not the browser error.
<3> what url are you testing
<3> http://something/home ?
<2> Snuffel: that's right, that url



<3> that should work
<2> p`u: yes, i'm reading the error_log actually
<1> dubTV: and your access file is in your document root?
<3> turn rewrite logging on so that you can see what is parsed and why it fails
<2> 06:05:15:27 -0800] "GET /home HTTP/1.1" 400 311
<2> i've already changed it to RewriteRule ^/home$ home.html
<2> SNuffel: how do i turn on the rewrite logging ?
<3> put RewriteLog <path to file> and RewriteLogLevel 5 all the way at the bottom of httpd.conf
<3> and restart
<3> what OS?
<3> http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html#RewriteLog
<4> http://httpd.apache.org/docs-2.0/mod/mod_rewrite.html#rewritelog
<3> hehe
<2> winXP
<2> okay hold on
<3> ok make that c:\rewrite.log then
<2> lemme put those lines
<1> ^/ will never match when used from an access file.
<3> why is that?
<1> because apache strips the url-path that matches the directory.
<3> that's nice to know
<3> i didn't know that
<2> Snuffel, i did what you did, and i get the "GET /home 400 311" error yet, the log file is empty
<2> lemme strip the /
<3> empty? but it's still there?
<2> as pointed by twkm
<3> has it been created by apache?
<2> it was created by apache and it's 0kb (empty)
<3> what is your loglevel?
<1> rewrite loglevel, of course.
<2> 5
<3> hm
<3> now i am confused
<2> this is frustrating :(
<3> my log was growing FAST when I turned it on and set it to 5
<3> everytime you make a request tons of lines are written to it
<2> how do i know if the module was successfully loaded, and is working such as mod_rewrite ?
<3> well if the logfile was created something is working i'd say
<3> and AllowOverride is On?
<3> in httpd.conf?
<2> AllowOverride All
<3> right
<3> that's what i meant
<3> try rewriting everything to home.html
<3> see if that works
<2> hold on
<2> the same :(
<2> 400 311 error :(
<3> and the log file is empty?
<1> dubTV: you know that mod_rewrite was loaded because the rewrite directives are not rejected.
<3> in that case something else is wrong
<2> twkm: thanks, yes, that's right.
<2> Snuffel: something is terribly wrong as log file is still empty
<1> dubTV: probably apache cannot write it.
<2> i've restarted apache > 5 times already just now :(
<3> twkm: if that were the case you'd see that in the errorlog
<3> dubTV: can you access 'normal' urls?
<2> Snuffel: all i see in the error_log is url accessed does not exist
<2> Snuffel: yes, i can view normal urls such as home.html



<3> where is the .htaccess file?
<3> you *did* name it .htaccess did you?
<3> i know windows can be a pain in the *** when it comes to renaming files to .files
<3> i did that in a dos box (win2k3)
<2> snuffel, i am not using the .htaccess now anymore
<3> oh
<2> i've plugged my rewrites directly to httpd.conf now
<2> i've changed it just now, and it's still not working though
<2> same issue, same **** out of my misery
<3> changed it to what?
<2> i've removed all the .htaccess
<2> and placed the RewriteRule inside httpd.conf
<1> dubTV: in the server config you would need ^/home$ as the pattern.
<3> no matter what the rule is , if the RewriteLogLevel is higher than 0 it should put something in the logfile
<2> twkm: i am aware of the /
<2> i've added it already
<3> hmmm
<3> of you set the target to http://www.google.com does that work?
<2> if i add [R] at the end, it redirects to home.html
<2> if i remove it, it can't resolve
<2> i'll try the google
<2> Snuffel, the google works
<3> hmmm
<2> does that mean, i have to include the entire SERVER_NAME ?
<3> i don't know
<3> you have reproduced an error i found using google
<3> [R] means external redirection
<3> i don;t know what that does yet
<1> if you want a redirect you should provide the scheme and host.
<2> twkm: i don't want a redirect actually
<1> if you do provide scheme and host then [R] is implied, even for locale targets.
<2> i want my links to remove the .html extensions
<3> I have been working with modrewrite for one evening and that was monday evening
<1> so "rewriterule ^/home$ /home.html" is not working?
<2> twmk: yes it's not working :(
<1> and you cannot get rewrite logging to work? is the rewritelogfile writable by the user or group under which apache children are running? is the rewriteloglevel greater than zero?
<2> now i i understand a li'l
<2> i was reading something online
<2> it said the order of loading the modules affect how requests are p***ed ?
<2> so i added [PT] for p*** thru
<2> and it works
<2> lemme try to re-order where i invoke php
<1> fyi, content negotiation can also provide extentionless support.
<3> i think i know what it is
<1> extensionless
<3> /home.html also matches /home
<1> but /home.html does not match ^/home$
<3> so the rule might go off over and over again
<3> oh
<3> no
<3> never mine
<3> mind
<1> if that were so an error 500 would result when the recursion limit was exceeded.
<2> hold on, restarting httpd
<3> you're right
<3> did you specify a RewriteBase?
<2> twkm+Snuffel: logfile is writable yes
<2> can u expound just a li'l on the "extensionless" thing?
<2> also on the nature of [PT] ?
<2> "RewriteBase /" right Snuffel ?
<1> see http://httpd.apache.org/docs/2.0/content-negotiation.html
<3> dubTV: yeah try it
<3> i don't know what apache uses as the base when it's not specified
<3> does it use the servername?
<1> .apachedoc rewritebase url
<4> rewritebase(mod_rewrite) url: http://httpd.apache.org/docs-2.0/mod/mod_rewrite.html#rewritebase
<2> ok, i'll get back to you guys, i'll check out the content-negotation section
<3> i am going to bed
<2> ok thanks Snuffel
<2> twkm: can u give me a gist why the p***thru [PT] seem to work?


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #apache
or
Go to some related logs:

#linux
What race of people suffered an estimated 35 million deaths at the hands of the
#chatzone
span tag + onclick event with parent
#AllNiteCafe
#skype
#linuxhelp
#java
c++++++++++++++++++++++++++++++++++++++
#skype



Home  |  disclaimer  |  contact  |  submit quotes