+ Reply to Thread
Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: htaccess problem?

  1. #1
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default htaccess problem?

    I have two urls that use the same base code (Drupal) but different databases (naturally) on web4.

    The first, pearhead.org, is installed in it's proper directory (pearhead.org).

    The second, mnsnowmobileconditions.com, is symlinked to the pearhead.org directory.

    If I enable PHP5, pearhead.org reports that register_globals and mbstring_extension is off. At the same time, mnsnowmobileconditions.com says that it's on.

    The four relevant lines in the htaccess file (I think):

    AddType application/x-httpd-fastphp .php
    Action application/x-httpd-fastphp /php-fastcgi/php-cgi
    php_value mbstring.http_input pass
    php_value mbstring.http_output pass

    I fail to understand why one site sees these things as on while the other sees them as off.

    If I take out the directive to switch to php5 then both sites switch back to php4 (and the problem goes away - except I need to use php5 now), so I know the file is being processed for each site.

    Any ideas?

  2. #2
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default

    Anyone at all?

  3. #3
    Ray
    Ray is offline
    I can't do everything.
    Join Date
    Jun 2004
    Location
    Plymouth, WI
    Posts
    134

    Default

    I've not seen any issue like this before. I've just tested a similar setup with symlinks, and I'm not seeing any issue with a difference in configurations.

    To disable register_globals, you can add the following line to your .htaccess file:

    php_flag register_globals off

    I'm really don't understand why the sites would have different settings, if they're using the same .htaccess file. Do you have a php settings page that can be compared between the two domains? In other words, something with the following line in it:

    <?php
    phpinfo();
    ?>

    If not, you might want to create a page like "phpinfo.php" to see if PHP is actually passing the values differently for the two domains.
    Ray Tetzloff


  4. #4
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default

    Thanks for the reply Ray.

    The forum software won't let me post links as apparently I haven't posted enough posts here... So you'll need to assemble these yourself.

    All can be accessed from either the pearhead.org domain or mnsnowmobileconditions.com domain:

    pdf/pearhead.org.php4.pdf
    pdf/pearhead.org.php5.pdf
    pdf/mnsnowmobileconditions.php4.pdf
    pdf/mnsnowmobileconditions.php5.pdf

    These were PDFs were generated from their respective domains.

    I'm not entirely sure what I'm looking at/for. I do notice that register_globals is off on one and on for the other.

    Keep in mind that to switch between php4 and php5 I modified one .htaccess file.

  5. #5
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default

    Quote Originally Posted by Ray View Post
    To disable register_globals, you can add the following line to your .htaccess file:

    php_flag register_globals off
    That flag is already in the .htaccess file when I switch it to php5.

  6. #6
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default

    Just for kicks I tried modifying another value to see if it showed up correctly.

    I modified smtp_port to 99. When looking at phpinfo() it shows up as 99 on pearhead.org but 25 on mnsnowmobileconditions.com.

  7. #7
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default

    This almost appears to be like the htscanner isn't parsing the file that is through a link.

  8. #8
    Ray
    Ray is offline
    I can't do everything.
    Join Date
    Jun 2004
    Location
    Plymouth, WI
    Posts
    134

    Default

    This is really strange. I've definitely never seen anything like this in the past. Like I say, I've tested it on a site of my own, and it seems to working fine through the symlink. I'm on a different web server than you are, but the configurations shouldn't be different enough to make a difference in that regard.

    I would probably have to recommend opening a ticket for this. I really don't have any ideas.

    Is that the entire content of the .htaccess file?
    Ray Tetzloff


  9. #9
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default

    No, it's not the entire contents.

    http://www.pearhead.org/htaccess.php4
    http://www.pearhead.org/htaccess.php5

    I'll open a ticket as well. Thanks!

  10. #10
    Member
    Join Date
    Jan 2008
    Posts
    36

    Default

    Just for kicks, I created this .htaccess:

    http://www.pearhead.org/htaccess.basic

    To see if the problem was related to anything else in the php5 file.

    It didn't change the symptoms at all.

+ Reply to Thread
Page 1 of 2 12 LastLast

Posting Permissions

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