Duke's Blog

Visit Duke's new and improved Blog.


Not my Domain Name Pointing to my Website

I have an interesting scenario.

I have an interesting scenario. A domain name which I do not own is pointing to my website. The owner of the domain will not take down the domain forwarding. The main reason this is a bad deal is search engines. When search results include my website, the other domain shows up in the results. This implies that my website is associated with their website. Not so as their is no association.

So I believe I found a solution. .htaccess which is used for site-access issues. I create an .htaccess rule to redirect the unwanted url to an error page on my website. I hope that the search engines will crawl my pages -soon- and push the unwanted search results so far down that the search results will appear irrelevant.

RewriteCond %{HTTP_HOST} ^www.bad-doamin.com$ [NC]
RewriteRule ^$ http://www.dukesnuz.com/403.shtml [L,R=301]

RewriteCond %{HTTP_HOST} ^bad-doamin.com$ [NC]
RewriteRule ^$ http://www.dukesnuz.com/403.shtml [L,R=301]
More information describing .htaccess can be found here.
catagory: Coding
tags: url,domain,.htaccess

My Pictures

Duck in Charles River Boston

This blog will contain posts that seem relevent and interesting to me. I hope you also enjoy them and find this blog useful.

I am using a model view controller (MVC) pattern for this web page. I using PHP for the controller, HTML for the view and for the modal mySQL. I also developed a Filemaker solution. The FM solution stores the blog data. I use the execute SQL script to upload, edit and delete all blog post data. The code can be found on GitHub. PHP files on GitHub. HTML file on GitHub