1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.3 Missing Style in Admin CP

Discussion in 'Troubleshooting and Problems' started by Gossamer, Feb 11, 2015.

  1. Gossamer

    Gossamer Active Member

    So, I recently moved my forum to a new host. Part of the move involved moving from a parked domain to a subdirectory of the main domain on a new host. I have my htaccess removing the subdirectory from the url (so it looks like sitename.com instead of sitename.com/subdirectory). Everything is working great accept for the admin CP.

    When I go in there, it loads like this:
    However, if I navigate to it with the subdirectory included in the url, it loads just fine. It just seems to fail without the subdirectory in the url.

    In short:
    • website.com/admin.php (missing admin cp styles -- I'd like to fix this)
    • website.com/subdirectory/admin.php (working perfectly)
    Any tips on how I can fix this so that it can load without the subdirectory being included in the url?
    Last edited: Feb 11, 2015
  2. Mike

    Mike XenForo Developer Staff Member

    This appears to be something related to your server configuration. It's ignoring (or removing?) parts of the query string, particularly the ones without a named value. The following 2 pages should load the same thing:


    Only the latter works. However <url>/index.php?_=help/ does work, which indicates it's an issue with non-named parameters. Your host may be able to provide some guidance. If you submit a ticket with ACP access details, we might be able to give more guidance (though it's very likely to be a server issue).
  3. Gossamer

    Gossamer Active Member

    Thanks! I'll try checking with my host. Though could this have something to do with my url rewrite rule in .htaccess?

    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^www\.pandorarp\.com [NC]
    RewriteRule ^(.*) http://pandorarp.com/$1 [L,R=301]
    RewriteRule ^$ insidethebox/
    RewriteCond %{REQUEST_FILENAME} !-f 
    RewriteCond %{REQUEST_FILENAME} !-d 
    RewriteRule ^(.*)$ insidethebox/$1
    It's a bit tricky for me to test right now, since the dns is still propagating, so I keep getting switched back and forth between the old and new server. :)
  4. Brogan

    Brogan XenForo Moderator Staff Member

    You can edit your Windows hosts file to prevent that.
  5. Mike

    Mike XenForo Developer Staff Member

    I would say that it's pretty likely to be related to your custom rewrite there but I'm not positive. I have seen people run into problems with URLs when trying to do something similar to what you're doing. It's much preferable to setup the document root for your domain such that the files exist naturally at the URL you're accessing.
  6. Gossamer

    Gossamer Active Member

    This is cool, thanks!

    Yeah, if I can't figure out a fix for this, that's probably what I'll end up doing. I planned on using my hosting for multiple sites, so I'd prefer a neater directory structure (folders for each site, instead of folders for other sites mixed in with the XF structure). But you do what you gotta do.


Share This Page