Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Senior Coder
    Join Date
    Feb 2003
    Location
    Ontario, Canada
    Posts
    1,223
    Thanks
    0
    Thanked 0 Times in 0 Posts

    mod_rewrite pattern works on Linux box, but crashes Apache on Windows

    Code:
    RewriteRule ^(([a-zA-Z]+/?)+)((([0-9]+)/([a-zA-Z]+))/?)?$ index.php?path=$1&id=$5&action=$6 [QSA,NC,L]
    This rule matches any number of 'alphanumeric/' followed by an optional 'numeric/string' followed by an optional '/'.

    So:
    abc/
    abc/def/ or
    abc/def/123/ghi/

    None of the trailing slashes are required for the pattern. But, for some reason, Apache.exe goes into an infinite loop when I try to visit:

    xxx.xxx.xxx.xxx/functions/livecounter/livecounter.php
    or
    xxx.xxx.xxx.xxx/functions/livecounter/livecounter.txt

    It doesn't mind 'xxx.xxx.xxx.xxx/images/portfolio/9-t.jpg' though. The only thing I can think of is some weird (and in my case, crippling) bug that causes Apache on Windows (using XP Pro SP2) to start using 100% CPU when the pattern matches 'a/b/b.ext' But I'll test further.

    Anyone have any experience with this? It's a long shot, but figured I'd try.

    Thanks,
    Aaron

    Edit: Seems it doesn't mind a/b/b.txt. But functions/livecounter/livecounter.txt kills it. functions/livecounter/b.txt works fine. functions/livecounter/livecounte.txt (no 'r' in filename) crashes it. What. The. !#&@
    Last edited by AaronW; 01-11-2005 at 09:40 PM.

  • #2
    Regular Coder
    Join Date
    Feb 2005
    Location
    UK
    Posts
    133
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Is there any info in the error.log under apache?


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •