[web] direct Domain to correct folder.

Discussion in 'Web Design & Coding' started by Vanquished, Mar 3, 2011.

  1. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    Hey guys,
    I have a new site AdWhois - Lounge going to that address doesn't work right, for some reason something is messed up and people can't log in from there. What does work, is http://www.adwhois.com/content.php I am fine with just getting the domain to go to that address but I can't figure out how to get it to work. I've fiddled around with .htaccess at a basic level.

    This is what I have in the .htaccess file right now

    DirectoryIndex /forum/content.php
    AddType x-mapp-php5 .php

    And I have the .htaccess file in the folder "/Adwhois" which is where the domain on 1and1 is pointed to.

    I've seen some really complicated things regarding .htaccess on the internet but I can't imagine it needs to be that hard...

    I've tried directing the domain through 1and1 to "/Adwhois/forum/content.php" and /Adwhois/forum" but neither work correctly. I also can't forward the domain to the correct one (I'm assuming because this is the original domain, not an additional one) any help would be amazing.

    Thanks!
     
  2. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
    uh run that by me again in english?

    Checking your first link looks okay anyway...
     
  3. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    I am trying to get my domain Adwhois.com to point to Adwhois.com/forum/content.php I have tried the things that I mentioned in the first post, that excerpt of text is from the .htaccess.
     
  4. Johnny

    Johnny .. Commodore .. Political User

    Messages:
    5,015
    Location:
    Happy Valley
    What portal are you using? there may be something in there that will allow you to set the default section for the url.
     
  5. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
    Change DirectoryIndex /forum/content.php to DirectoryIndex forum/content.php

    Assuming your host allows you to use that directive in the .htaccess file.
     
  6. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    Where would I find that?
    I know the database is through perfora.net but I'm assuming thats not what I'm looking for?

    Funny you should say that, I was looking at the .htaccess files I use for theosr.com and realized I didn't have the "/" in front of forum so I was all optimistic but it still didn't work.

    Thanks guys
     
  7. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
  8. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    Haha,
    Thanks. I literally just sumbled upon that link. Now since you posted it, I know thats what I must do.
    Is that what a portal is?

    Thanks again!
     
  9. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    Wow thats complicated.
    Now I just need to figure out what I actually need to post to redirect adwhois.com to adwhois.com/forum/content.php lol
     
  10. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
    I'm sure your webhost could help with this too :)

    I'd get it sorted it in minutes if it were hosted on my server.
     
    Vanquished likes this.
  11. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    Haha, im sure you would.
    I talked to 1and1 before asking here, and they said that .htaccess was beyond their support ability and just use the domain transfer setting (which is hilarious because they've helped me with .htaccess in the past)

    I wonder if this is what I'm looking for though:
    1&1 Webhosting FAQ | Modifying Apache Webserver configuration
     
  12. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    Ugg, maybe I just need to reinstall the forum or something. The .htaccess does work in its basic form

    If I put:
    Code:
    DirectoryIndex forum/forum.php
    AddType x-mapp-php5 .php
    
    instead of

    Code:
    DirectoryIndex forum/content.php
    AddType x-mapp-php5 .php
    It does direct the url to the forum, however it doesn't work, logging in doesn't work and everytime I load a page I get some error message about previous session or something (from the forum, not the server) I just don't know, maybe if I install it not in the /forum folder and just at the /Adwhois folder it will work.
     
  13. Vanquished

    Vanquished Mr. Bananagrabber Political User

    Messages:
    4,868
    Location:
    Massachusetts
    Alright then, lets see if this continues to work.

    I did a little more digging and decided it might be a problem with the forum. It turns out, it might have been something with where the cookies were being stored.
    I have changed the location to the parent directory and it seems to be working for right now.

    Thanks for all your help!
     
  14. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
    Well if you ever get fed up of 1&1 give me a shout and we'll see if we can work out a deal :)