Forum Moderators: phranque

Message Too Old, No Replies

Domain Name in Address bar

         

sharp21

8:20 am on Jan 13, 2008 (gmt 0)

10+ Year Member



Hey
Im sure there is a simple solution to this, but im still learning...
Ive got a registered domain pointed at my hosted site.
When I type in the domain address, it will go to my page, but it redirects to the hosts name.
Ex.
i type: mysite.com
& it goes to: mysite.freehost.com

The DNS servers are okay, so it has been suggested its in my code somewhere. Would this be something the .htaccess file handles? If so, how can I change it to just display my registered domain name?
Its a wordpress built site if that helps.
Thanks
S.

jdMorgan

3:54 pm on Jan 13, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



It could be something in your .htaccess file, or it could just be the 'cost' of using a free host -- something the host is doing in their server configuration that you cannot change using .htaccess.

If you have any plans for this site other than as a 'hobby site' for you and your family and friends, then using 'free' hosting may turn out to be a very expensive mistake. If you build a 'brand' and start getting lots of traffic, and then have to change your domain name, you'll lose your search rankings and traffic -- at least for awhile, and maybe for up to a year. Since you've got this redirect happening, your domain name *is* freehost.com, so that's why this is a concern.

Free hosting can be very expensive. It is also usually quite limiting from a technical perspective. In general, it's usable for personal and hobby sites only.

Jim

wheelie34

3:59 pm on Jan 13, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



First you need to pin down the cause.

Are you 100% sure the domain has the A records pointing to the hosting server and are they an IP address, your registrar may have domain forwarding on it instead

I see you said "mysite.freehost.com" some free hosts do auto forwarding to user.freehost.com

What does the view source tell you some free hosts can automatically add refreshes to a page.

Download the .htaccess file and read its contents.

One of the above should show something, it's a start atleast.

sharp21

9:52 pm on Jan 13, 2008 (gmt 0)

10+ Year Member



I posted on the host forum about the problem & it seems I should be able to have my dedicated name...
Viewing the source, every post or commands href=page.host.com
That IS where the files are located, but my registered name is attached to the account & it is my understanding that it should replace the hosts name in the address.
Ill check the other things that were suggested.
Thanks
S.

g1smd

10:12 pm on Jan 13, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



The URLs in links define what the URL is for the page they point to.

sharp21

10:51 pm on Jan 13, 2008 (gmt 0)

10+ Year Member



Yeah or where the file is located on the server.
What im saying is that reading through the source, I cant see where the redirect is.
S.

sharp21

1:06 am on Jan 14, 2008 (gmt 0)

10+ Year Member



Hmm, when I connect my ftp to the server, it doesnt show the htaccess file, for me to download!
It shows it on my file manager page from the website, but i cant download it from there... It doesnt show it on the phpAdmin page either.
On another forum it was suggested that i delete the file. Not something im gonna do without some more info first!
S.

edit: This is what it says on the host site regarding alternate address

Extra domain
Add a valid domain name(.com, .co.uk etc). After adding this domain both the domain and previous subdomain will operate on your account.
Domains must be registered through an external registrar.

Can domains be www.?
Yes, you must add it from your control panel >> account settings.

Please type in the box, www.yourdomain.com, however [yourdomain.com...] will then no longer work

g1smd

1:24 am on Jan 14, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



In your FTP client there will be a simple option that is currently hiding those entries that start with a dot in the filename.

You will need to change that setting in order to see the file and download it. Always download the existing file and modify it.

sharp21

3:45 am on Jan 14, 2008 (gmt 0)

10+ Year Member



Okay, got it, downloaded it, opened it...
All it has in the file is a picture (with broken link)
then under that it has a link called Home
Not what I was expecting.
S.

jdMorgan

4:09 am on Jan 14, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Open it as a plain-text file, using Notepad, for example. You may find it easier to work with if you rename it "htaccess.txt" while working on your PC, then rename it back to .htaccess once it has been uploaded to your server.

Do not edit .htaccess files with anything other than a plain-ASCII text editor.

Jim

sharp21

5:08 am on Jan 14, 2008 (gmt 0)

10+ Year Member



Did that, now when I open it it reads:

# BEGIN WordPress

# END WordPress

Thats all that is in it
S>