Zaventh Posted August 3, 2005 Share Posted August 3, 2005 Okay, "level 2" support said it wasn't their problem and I should try here--but I somehow still think it is the way the second domain is setup but here goes anyway. I've previously had one domain (zaventh.com) running Mediawiki at http://www.zaventh.com/wiki . Now, I wanted to simply throw a new domain on top of that (nexuswiki.com) so that if you went to zaventh.com/wiki, it would be the exact same as nexuswiki.com/wiki. TCH parked the second domain for me, and I have it all setup as you would expect a domain should be. Now, if one navigates to www.nexuswiki.com/wiki, it automatically rewrites the url to be pretty, and it should take you to http://www.nexuswiki.com/wiki/index.php/Main_Page, but it doesn't. Instead it takes you to http://www.zaventh.com/wiki/index.php/Main_Page. At first I thought perhaps the domain wasn't working right, but if you navigate to http://www.nexuswiki.com/wiki/index.php/Main_Page it works fine and as expected, except that if you save an edited page, it will redirect you back to the right page, but with the zaventh.com domain in place of nexuswiki.com. My next and logical assumption was that it was using the domain name as a variable somewhere, but I couldn't see any obvious place to set it as it wasn't in the main config. So, I first search the entire mysql database, and there are 0 reference to either domain there. Next, I downloaded every file in the wiki and >grep -i "zaventh" *.* 'd them all, and nothing came up. Nothing for the other domain either. This is what led me to believe somehow that nexuswiki.com was somehow resolving to zaventh.com, and when a redirect was called on the wiki, that is where it was going. At any rate, if I would navigate to http://www.nexuswiki.com/index.php, it still wouldn't work right. The only thing between index.php and Main_Page is redirect.php. None of these files contain any actual domain names, but rather are used to rewrite the url I believe. I have attached these files, though I can't really see anything in them that would be causing the problem I am having. Any help or ideas of where else to look would be great... Thanks. index.php redirect.php Quote Link to comment Share on other sites More sharing options...
TweezerMan Posted August 3, 2005 Share Posted August 3, 2005 I'd suggest looking at your .htaccess file(s) and see if there are any redirect or mod_rewrite directives that might perform a redirect from zaventh.com to nexuswiki.com. Quote Link to comment Share on other sites More sharing options...
Zaventh Posted August 3, 2005 Author Share Posted August 3, 2005 I'd suggest looking at your .htaccess file(s) and see if there are any redirect or mod_rewrite directives that might perform a redirect from zaventh.com to nexuswiki.com. <{POST_SNAPBACK}> Oh.. I thought of that too, so right now my .htaccess file is empty. MediaWiki doesn't include it's own .htaccess file except for in the subdirs which just deny access to them, so I forget what was in the original .htaccess but it was nothing related to mediawiki... Quote Link to comment Share on other sites More sharing options...
section31 Posted August 4, 2005 Share Posted August 4, 2005 so did you fix it because it seems to be working on my end. Quote Link to comment Share on other sites More sharing options...
Zaventh Posted January 26, 2006 Author Share Posted January 26, 2006 Is there anyone who can help me with this same problem again? Previously "TCH-Rick" resolved my issue and it has been working fine until recently. I PMed him but he appears to be unavailable. Thank you. Quote Link to comment Share on other sites More sharing options...
TCH-Andy Posted January 26, 2006 Share Posted January 26, 2006 Mediawiki modified the URL to make it "tidy" in two places. A key one is through your .htaccess. I'd guess that somewhere you have some of the redirects in there with a domain name included. The other one is within a php redirect file. Did you change anything (upgrade) when it stopped working Quote Link to comment Share on other sites More sharing options...
Zaventh Posted January 26, 2006 Author Share Posted January 26, 2006 (edited) I think I did in fact upgrade it a few months back (to the latest minor revision). However, the .htaccess file should not have changed since it was something I added on later anyway and is not included with mediawiki by default. Here is the file below: >php_value upload_max_filesize 10m RewriteEngine on # uncomment this rule if you want Apache to redirect from www.mysite.com/ to www.mysite.com/wiki/Main_Page RewriteRule ^$ /wiki/Main_Page [R] # do the rewrite RewriteRule ^wiki/?(.*)$ /w/index.php?title=$1 [L,QSA] If I disable the bottom rewrite line, it seems to not forward to my first domain anymore... but then the urls are terrible. I don't see how that line could come up with "zaventh.com" either... since it is still no where in any configuration or variable in mediawiki. EDIT: For some more info, I have tried many other solutions of getting this to work as layed out here: http://meta.wikimedia.org/wiki/Eliminating...hp_from_the_url But none except the above mentioned .htaccess rewrite ever worked for me. Edited January 26, 2006 by Zaventh Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.