Go Back   CodingForums.com > :: Client side development > General web building

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 02-06-2013, 04:33 AM   PM User | #1
Kevin_M_Schafer
Regular Coder

 
Kevin_M_Schafer's Avatar
 
Join Date: Apr 2011
Location: Fairfax, Minnesota, U.S.A.
Posts: 482
Thanks: 97
Thanked 17 Times in 17 Posts
Kevin_M_Schafer is an unknown quantity at this point
Trying to get clean URL displayed for Wordpress install in subdomain folder

I'm trying to use Web Site Forwarding to attach one of my domain names to a Wordpress installation that is created inside of a subdomain folder. It installs and then I can't log in unless I use the full url, which includes my host domain, like this: www.maindomain.com/subdomain.com

Here's my folder configuration regarding my hosting:

www.maindomain.com/public_folder/subdomain.com

I would like to have perhaps two or three Wordpress installations in three different subdomain folders, each having completely different domain names.

I can successfully install Wordpress sites in multiple folders all day long on the same server. That's not my problem. What I'm trying to do is have a clean URL displaying when a particular Wordpress site opens. I don't want: www.maindomain.com/subdomain. I just want: www.subdomain.com.

Is this possible? If it wasn't for the messy URL when the site opens, I'd be set. Now that I've applied Web Site Forwarding, my clean URL is unworkable.

I'm trying to avoid purchasing multiple hosting packages. Any multiple sites I construct are for my own use, not someone else's.

Any help would be most appreciated. Thanks.

Kevin
__________________
My keyboard is an IBM from 1993 and I like it that way. | Who is Dan Well? Everyone always says I know Dan Well.Building a web page is like building a birdhouse. Put it up there and watch 'em come. | Maintaining the aspect ratio of an image is more important than having a cold orange pop.
Kevin_M_Schafer is offline   Reply With Quote
Old 02-06-2013, 10:01 AM   PM User | #2
VIPStephan
The fat guy next door


 
VIPStephan's Avatar
 
Join Date: Jan 2006
Location: Halle (Saale), Germany
Posts: 7,584
Thanks: 5
Thanked 864 Times in 841 Posts
VIPStephan is a jewel in the roughVIPStephan is a jewel in the roughVIPStephan is a jewel in the rough
Sounds like you need to change the root path in your WP config or something like that. Of course you need the subdomain as root, not the main domain.
__________________
Don’t click this link!
VIPStephan is offline   Reply With Quote
Old 02-06-2013, 03:36 PM   PM User | #3
Kevin_M_Schafer
Regular Coder

 
Kevin_M_Schafer's Avatar
 
Join Date: Apr 2011
Location: Fairfax, Minnesota, U.S.A.
Posts: 482
Thanks: 97
Thanked 17 Times in 17 Posts
Kevin_M_Schafer is an unknown quantity at this point
Quote:
Originally Posted by VIPStephan View Post
Sounds like you need to change the root path in your WP config or something like that. Of course you need the subdomain as root, not the main domain.

Thanks, VIPStephan. I appreciate your reply. There seems to be something with my host provider, as I don't see a difference between a "Domain Addon" or a "Subdomain." It treats them as the same thing. I thought a subdomain was supposed to stay in front of the main domain in the URL address.

I'm going to make some more calls so I can understand this more thoroughly.

Kevin
__________________
My keyboard is an IBM from 1993 and I like it that way. | Who is Dan Well? Everyone always says I know Dan Well.Building a web page is like building a birdhouse. Put it up there and watch 'em come. | Maintaining the aspect ratio of an image is more important than having a cold orange pop.
Kevin_M_Schafer is offline   Reply With Quote
Old 02-06-2013, 05:33 PM   PM User | #4
SB65
Senior Coder

 
Join Date: Feb 2009
Location: West Yorkshire
Posts: 2,812
Thanks: 9
Thanked 681 Times in 675 Posts
SB65 will become famous soon enoughSB65 will become famous soon enough
Hi Kevin, how're you doing?

You should definitely be able to do this. I have a WP install on my main domain (myname.com), two further ones on different subdomains (testwp.myname.com and client.myname.com), and another one on an add-on domain (somethingdifferent.co.uk). All display their own domain names.

As Stephan says, it may be a case of changing the settings in the subdomain Wordpress installs.
__________________
Use the W3C HTML Validator and CSS Validator to check your code and Firebug to see what css is applied to an element
Read Steve Krug's book Don't Make Me Think - essential reading on web usability
I don't recommend much, but I do recommend Clook for UK web hosting
SB65 is offline   Reply With Quote
Old 02-06-2013, 06:24 PM   PM User | #5
Kevin_M_Schafer
Regular Coder

 
Kevin_M_Schafer's Avatar
 
Join Date: Apr 2011
Location: Fairfax, Minnesota, U.S.A.
Posts: 482
Thanks: 97
Thanked 17 Times in 17 Posts
Kevin_M_Schafer is an unknown quantity at this point
Quote:
Originally Posted by SB65 View Post
Hi Kevin, how're you doing?

You should definitely be able to do this. I have a WP install on my main domain (myname.com), two further ones on different subdomains (testwp.myname.com and client.myname.com), and another one on an add-on domain (somethingdifferent.co.uk). All display their own domain names.

As Stephan says, it may be a case of changing the settings in the subdomain Wordpress installs.

Hey SB65. Nice to hear from you -- and VIPStephan. A customer service agent of my host provider just informed me about 15 minutes ago that what I'm trying to do has nothing to do with Web Site Forwarding. He explained that it's all about first setting up the new domain to point at the folder where the WP file will be installed. He said then you worry about uploading the files and doing the install.

The fact that you're able to do this, SB65, makes me feel good. I've been thinking I was going to have to purchase additional hosting packages.

I'll post back with an update -- or to ask for some help.

Thanks,
Kevin
__________________
My keyboard is an IBM from 1993 and I like it that way. | Who is Dan Well? Everyone always says I know Dan Well.Building a web page is like building a birdhouse. Put it up there and watch 'em come. | Maintaining the aspect ratio of an image is more important than having a cold orange pop.

Last edited by Kevin_M_Schafer; 02-06-2013 at 06:24 PM.. Reason: text clarity
Kevin_M_Schafer is offline   Reply With Quote
Old 02-06-2013, 06:53 PM   PM User | #6
Kevin_M_Schafer
Regular Coder

 
Kevin_M_Schafer's Avatar
 
Join Date: Apr 2011
Location: Fairfax, Minnesota, U.S.A.
Posts: 482
Thanks: 97
Thanked 17 Times in 17 Posts
Kevin_M_Schafer is an unknown quantity at this point
SB65, VIPStephan,

The Addon Domain and Redirect works, but the URL shows the root directory domain name along with the new domain name.

I didn't use the ".com" for the addon domain folder like this "newdomain.com." Do I need the ".com"?

Other than setting up the "wp-config" file, I'm not familiar with any files inside of Wordpress that I can tweak regarding subdomains or addon domains. What files would these be? Do I need to tweak them prior to the installation?

Thanks,
Kevin
__________________
My keyboard is an IBM from 1993 and I like it that way. | Who is Dan Well? Everyone always says I know Dan Well.Building a web page is like building a birdhouse. Put it up there and watch 'em come. | Maintaining the aspect ratio of an image is more important than having a cold orange pop.

Last edited by Kevin_M_Schafer; 02-06-2013 at 06:54 PM.. Reason: text clarity
Kevin_M_Schafer is offline   Reply With Quote
Old 02-06-2013, 07:48 PM   PM User | #7
SB65
Senior Coder

 
Join Date: Feb 2009
Location: West Yorkshire
Posts: 2,812
Thanks: 9
Thanked 681 Times in 675 Posts
SB65 will become famous soon enoughSB65 will become famous soon enough
What happens if you just enter the add-on domain - does that result in the main domain showing in the URL? If so, then it's not set up properly.

To answer your question, f it's an add-on domain, not a subdomain, then it depends how the add-on domain has been set up. You can check this within cPanel if you have access to it - via Add-On domains - this will show you the folder set as the document root for the addon domain.

Note that both urls will work, so if you have anotherdomain.com as an add-on domain of mydomain.com, then both

mydomain.com/anotherdomain.com

and

anotherdomain.com

should give you the root page of anotherdomain.com.

For WP on the add-on domain, within the WP admin panel Settings > General you need to make sure that the Wordpress Address and Site URL are both set to anotherdomain.com and not mydomain.com/anotherdomain.com domain.

If you're running the install manually, make sure this is run from anotherdomain.com. If you've got Softaculous or something similar on your cPanel then that will do all the hard work for you and let you select where WP is installed.
__________________
Use the W3C HTML Validator and CSS Validator to check your code and Firebug to see what css is applied to an element
Read Steve Krug's book Don't Make Me Think - essential reading on web usability
I don't recommend much, but I do recommend Clook for UK web hosting
SB65 is offline   Reply With Quote
Users who have thanked SB65 for this post:
Kevin_M_Schafer (02-06-2013)
Old 02-06-2013, 10:13 PM   PM User | #8
Kevin_M_Schafer
Regular Coder

 
Kevin_M_Schafer's Avatar
 
Join Date: Apr 2011
Location: Fairfax, Minnesota, U.S.A.
Posts: 482
Thanks: 97
Thanked 17 Times in 17 Posts
Kevin_M_Schafer is an unknown quantity at this point
Thank you, SB65. I'm making very good progress with some help from an expert that saw my post here on CodingForums. Thanks for your tips as well. I've copied them for myself. I'm making a folder about this stuff so that I have it in the future. Man, I've been looking so hard and long for these answers. It's nice to finally have some progress.

I was going nuts not seeing the real results of the URL until I accessed my site from another one of my computers. It appears to be working. How do I get my Win7 computer, using Chrome, to refresh so that I don't see old information? I used Control F5 and that doesn't do any good. It always seems to take a couple of hours on this particular machine before my browser shows me the current, real information. Does anyone else have this problem?
__________________
My keyboard is an IBM from 1993 and I like it that way. | Who is Dan Well? Everyone always says I know Dan Well.Building a web page is like building a birdhouse. Put it up there and watch 'em come. | Maintaining the aspect ratio of an image is more important than having a cold orange pop.
Kevin_M_Schafer is offline   Reply With Quote
Old 02-07-2013, 01:30 PM   PM User | #9
SB65
Senior Coder

 
Join Date: Feb 2009
Location: West Yorkshire
Posts: 2,812
Thanks: 9
Thanked 681 Times in 675 Posts
SB65 will become famous soon enoughSB65 will become famous soon enough
I've found that clearing the browser cache and then flushing your PCs DNS cache works. Flush the DNS cache by running:

Code:
ipconfig /flushdns
from the command line prompt.
__________________
Use the W3C HTML Validator and CSS Validator to check your code and Firebug to see what css is applied to an element
Read Steve Krug's book Don't Make Me Think - essential reading on web usability
I don't recommend much, but I do recommend Clook for UK web hosting
SB65 is offline   Reply With Quote
Users who have thanked SB65 for this post:
Kevin_M_Schafer (02-07-2013)
Old 02-07-2013, 01:41 PM   PM User | #10
Kevin_M_Schafer
Regular Coder

 
Kevin_M_Schafer's Avatar
 
Join Date: Apr 2011
Location: Fairfax, Minnesota, U.S.A.
Posts: 482
Thanks: 97
Thanked 17 Times in 17 Posts
Kevin_M_Schafer is an unknown quantity at this point
Quote:
Originally Posted by SB65 View Post
I've found that clearing the browser cache and then flushing your PCs DNS cache works. Flush the DNS cache by running:

Code:
ipconfig /flushdns
from the command line prompt.

That did it! It only took me half a minute. Thanks, SB65. I won't forget it!

Kevin
__________________
My keyboard is an IBM from 1993 and I like it that way. | Who is Dan Well? Everyone always says I know Dan Well.Building a web page is like building a birdhouse. Put it up there and watch 'em come. | Maintaining the aspect ratio of an image is more important than having a cold orange pop.
Kevin_M_Schafer is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 04:35 AM.


Advertisement
Log in to turn off these ads.