nvblog
Forum Replies Created
-
Alright, i figure this out but don’t know if this is the correct way to do it. It does what I wanted for now. It blocks access to the folder that is used by the subdomain.
Inserted this code at the top of index.php file.
<?php
$_SERVER[HTTP_HOST] = strtolower($_SERVER[HTTP_HOST]);
if($_SERVER[HTTP_HOST]!== “blog.nepalvista.com”) {
?>
<html>
<head>
<title>Oops, that’s the wrong address for this blog!</title>
<meta name=”robots” content=”nofollow,noindex”>
</head>
<div>
<center>
Then I gave some message here about the address of my blog but have not provided any links. Users will copy paste the address to their browser to view the site. If I have a link here, i fear search engines will follow… i don’t know if that’s good even with a rel=”nofollow” tag.
</center>
</div>
</body>
</html>
<?php
exit();
}
?>
<?php
/* Short and sweet */
define(‘WP_USE_THEMES’, true);
require(‘./wp-blog-header.php’);
?>This has solved my problem, but I don’t know if this is the way to do correctly.
I would love your suggestions and further help. Instead of showing messages to users, should i automatically redirect them to the the blog address (which is the subdomain address blog.nepalvista.com) Will automatic redirection hurt search engines ?
Thank you in advance for any suggestions, etc.
WordPress rocks! and i hope future developments makes wordpress blogs free from duplicate contents!!!
thak you thank you thank and
“I hope you will visit Nepal someday!”