1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Subdomain redirect

Discussion in 'Apache' started by tandiono, Sep 29, 2005.

  1. #1
    Hi! im new here. I hope i post at the right thread.. anyway how can i make my subdomain redirect to other site?
    something like this : free.blobal.com
    sdsd.blobal.com
    kewwefrw.blobal.com

    whatever is type in for the subdomain it will always redirect to blobal.com

    is there a way to set it?

    here is my .htaccess code:

    # -FrontPage-
    IndexIgnore .htaccess */.?* *~ *# */HEADER* */README* */_vti*

    <Limit GET POST>
    order deny,allow
    deny from all
    allow from all
    </Limit>
    <Limit PUT DELETE>
    order deny,allow
    deny from all
    </Limit>
    AuthName www.blabla.com
    AuthUserFile /home/vom/public_html/_vti_pvt/service.pwd
    AuthGroupFile /home/vom/public_html/_vti_pvt/service.grp


    Please help me. Thanks in advance
     
    tandiono, Sep 29, 2005 IP
  2. MiamiHost

    MiamiHost Peon

    Messages:
    238
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    0
    #2
    your using apache I presume, shouldnt there be some kind of Redirect permanent lines added
     
    MiamiHost, Oct 4, 2005 IP
  3. johnt

    johnt Peon

    Messages:
    178
    Likes Received:
    21
    Best Answers:
    0
    Trophy Points:
    0
    #3
    You need to add the following lines.
    RewriteEngine on
    RewriteCond %{HTTP_HOST} !^blobal.com
    RewriteRule ^(.*)$ http://blobal.com/$1 [R=301]
    
    Code (markup):
    That will redirect any subdomain ( including www. ) to blobal.com

    cheers

    johnt
     
    johnt, Oct 4, 2005 IP
  4. mikozv

    mikozv Well-Known Member

    Messages:
    430
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    108
    #4
    I have tried this but I dont know where should I paste that code :( Because I couldnt find htaccess file...
    I need to redirect my subdomain to my domain...
    Could someone please help me?
     
    mikozv, Dec 15, 2007 IP
  5. Bohol

    Bohol Peon

    Messages:
    2,680
    Likes Received:
    75
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Can I do this in cPanel?
     
    Bohol, Dec 15, 2007 IP
  6. mikozv

    mikozv Well-Known Member

    Messages:
    430
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    108
    #6
    I dont know but its for me very important to find .htaccess file or how to create it, where to create it,... Please give me an advice.
    :confused:
     
    mikozv, Dec 15, 2007 IP
  7. mikozv

    mikozv Well-Known Member

    Messages:
    430
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    108
    #7
    Problem resolved with

    <HTML>
    <HEAD>
    <TITLE>title goes here</TITLE>
    </HEAD>

    <FRAMESET COLS="100%">
    <FRAMESET ROWS="100%">
    <FRAME SRC="http://name.org/">
    </FRAMESET>
    </FRAMESET>
    </HTML>

    adding to index file. address of subdomain remain but content of the website will be changed ;)
     
    mikozv, Dec 15, 2007 IP
  8. nilesh.3892@gmail.com

    nilesh.3892@gmail.com Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #8
    dude, create a CNAME value in your DNS for

    subdom.dom.tld with data = redirpage.dom.tld
     
    nilesh.3892@gmail.com, Dec 15, 2007 IP