Web Hosting Forum | Lunarpages


*
Welcome, Guest. Please login or register.
Did you miss your activation email?



Login with username, password and session length
February 09, 2012, 04:59:07 PM

Pages: [1]   Go Down
  Print  
Author Topic: Proper Subdomain Redirection  (Read 272 times)
KeremWharton
Pong! (the videogame) Master
*****
Offline Offline

Posts: 26



WWW
« on: June 28, 2009, 07:44:26 PM »

Hello friends,

I have re-setup a blog and I'm using blog.keremgogus.com subdomain for it. I've used domain redirection but when you wrote blog.keremgogus.com to the address bar of browser then hit enter - it's showing the folder name of the blog as http://keremgogus.com/blog/

I want to have it with the blog subdomain address. is there a way to that - because all the blogs out there are working like that.

For example when want to you visit Mr Fire's blog. at www.mrfire.com - the blog subdomain address is blog.mrfire.com and it stays as it is (http://blog.mrfire.com/) Mine is turning into http://keremgogus.com/blog/

I hope I told my issue correctly - help appreciated Smile

Thanks in advance
Kerem
Logged

Kerem Gogus
- Prints On Zazzle: zazzle.com/kerem*
- Prints On dA: artofkerem.deviantart.com/store/
- Web Site: www.keremgogus.com
- My Blog: blog.keremgogus.com
- Myspace: myspace.com/keremwharton
MrPhil
Berserker Poster
*****
Offline Offline

Posts: 5083



« Reply #1 on: June 29, 2009, 06:57:44 AM »

public_html/.htaccess:

Code:
RewriteEngine On
RewriteRule   ^blog/?(.*)$   http://blog.keremgogus.com/$1  [R=301]
Logged

Mitch
Berserker Poster
*****
Offline Offline

Posts: 12838


WWW
« Reply #2 on: June 29, 2009, 06:58:54 AM »

That is an odd situation.  Check the .htaccess file inside of your /public_html/blog/ folder and try removing any redirects in there, to see if that might solve the problem.  Looks like it is redirecting it from blog.yourdomain.com to yourdomain.com/blog/.  Hope that helps!
Logged

New to Web Site Hosting? Check Out the Lunarpages Blog Hosting Guide!


Follow us @lunarpages on Twitter!
Important Threads: Read This Before Posting! | Lunarforums Rules! | Mitch's Link of the Day!
Also, be sure to check out and subscribe to the Lunartics Blog and the Lunarpages Newsletter !

Need Web Hosting Help? Check out the Lunarpages Web Hosting Wiki. It has tons of tips, tutorials and resources!
KeremWharton
Pong! (the videogame) Master
*****
Offline Offline

Posts: 26



WWW
« Reply #3 on: June 29, 2009, 08:37:04 AM »

Thank you guys! it was like that - the .htaccess on my blog folder:

RewriteEngine on

# BEGIN WordPress

# END WordPress

RewriteCond %{HTTP_HOST} ^blog.keremgogus.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.blog.keremgogus.com$
RewriteRule ^(.*)$ "http\:\/\/keremgogus\.com\/blog\/" [R=301,L]

--

I removed the last line and worked fine - http://blog.keremgogus.com/

Thanks a lot!  Thumbs Up
Logged

Kerem Gogus
- Prints On Zazzle: zazzle.com/kerem*
- Prints On dA: artofkerem.deviantart.com/store/
- Web Site: www.keremgogus.com
- My Blog: blog.keremgogus.com
- Myspace: myspace.com/keremwharton
Mitch
Berserker Poster
*****
Offline Offline

Posts: 12838


WWW
« Reply #4 on: June 29, 2009, 08:40:34 AM »

Awesome, happy to hear you got it working.  Thumbs Up
Logged

New to Web Site Hosting? Check Out the Lunarpages Blog Hosting Guide!


Follow us @lunarpages on Twitter!
Important Threads: Read This Before Posting! | Lunarforums Rules! | Mitch's Link of the Day!
Also, be sure to check out and subscribe to the Lunartics Blog and the Lunarpages Newsletter !

Need Web Hosting Help? Check out the Lunarpages Web Hosting Wiki. It has tons of tips, tutorials and resources!
Pages: [1]   Go Up
  Print  
 
Jump to: