Open Blog from Web Address

User avatar
adam
SilverLounger
Posts: 2347
Joined: 23 Feb 2010, 12:07

Open Blog from Web Address

Post by adam »

Hi,

I have a blog of my own.

What I'm wondering is that whether it's possible to open my blog page just by typing a website address like http://www.mynameonline.com/" onclick="window.open(this.href);return false;
in the web browser if the name of my blog is "mynameonline"

Otherwise do I have to create a website for that.

Any suggestion on this would be kindly appreciated.

Thanks in advance.
Best Regards,
Adam

User avatar
Leif
Administrator
Posts: 7207
Joined: 15 Jan 2010, 22:52
Location: Middle of England

Re: Open Blog from Web Address

Post by Leif »

adam wrote:Hi,

I have a blog of my own.

What I'm wondering is that whether it's possible to open my blog page just by typing a website address like http://www.mynameonline.com/" onclick="window.open(this.href);return false;
in the web browser if the name of my blog is "mynameonline"

Otherwise do I have to create a website for that.
Can you clarify <...if the name of my blog is "mynameonline"> Do you mean you have a blog at something like http://mynameonline.blogspot.com/ ?

Do you own the domain mynameonline.com?

If the answer to the above two questions is yes, then you can set up a redirect from the home page of www.mynameonline.com to take the viewer directly to http://mynameonline.blogspot.com/ :

Code: Select all

<SCRIPT LANGUAGE="JavaScript">
window.location.replace ("http://mynameonline.blogspot.com/");
</script>
Alternatively, I believe you can have your domain simply point to your blog address.
Leif

User avatar
adam
SilverLounger
Posts: 2347
Joined: 23 Feb 2010, 12:07

Re: Open Blog from Web Address

Post by adam »

Thanks for the reply Leif.
Yes, the name of my blog is http://mynameonline.blogspot.com/" onclick="window.open(this.href);return false;

I do not own the domain mynameonline.com

Does this mean if I want to get what I have said in Post 21920 I have to first get a domain for that?
Best Regards,
Adam

User avatar
Leif
Administrator
Posts: 7207
Joined: 15 Jan 2010, 22:52
Location: Middle of England

Re: Open Blog from Web Address

Post by Leif »

adam wrote:Thanks for the reply Leif.
Yes, the name of my blog is http://mynameonline.blogspot.com/" onclick="window.open(this.href);return false;

I do not own the domain mynameonline.com

Does this mean if I want to get what I have said in Post 21920 I have to first get a domain for that?
Yes - if the domain does not exist it will not be found by any browser and will therefore not be able to redirect to your blog in any circumstances.

There would also be a conflict if someone else obtained mynameonline.com - typing that into a browser would take you to their domain, not your blog.
Leif

User avatar
adam
SilverLounger
Posts: 2347
Joined: 23 Feb 2010, 12:07

Re: Open Blog from Web Address

Post by adam »

Anyways, Thanks for the reply.
Best Regards,
Adam

User avatar
ChrisGreaves
PlutoniumLounger
Posts: 15576
Joined: 24 Jan 2010, 23:23
Location: brings.slot.perky

Re: Open Blog from Web Address

Post by ChrisGreaves »

Am I doing something wrong?
Leif wrote:If the answer to the above two questions is yes, then you can set up a redirect from the home page
Thanks Leif. I tried this as method (2).
Method (1):

Code: Select all

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Chris Greaves's Home page</title>
<meta http-equiv="REFRESH" content="0;url=http://www.chrisgreaves.com/WP/"></HEAD>
<BODY>
I have moved to a WordPress fabrication.
</BODY>
</HTML>
Method2:

Code: Select all

<SCRIPT LANGUAGE="JavaScript">
window.location.replace ("http://www.chrisgreaves.com/WP/");
</script>
My owned domain is http://www.ChrisGreaves.com" onclick="window.open(this.href);return false;, so I have tried two methods of creating http://www.chrisgreaves.com/index.htm" onclick="window.open(this.href);return false;

In both cases I go to the URL bar of my browser (F6 in FireFox), type "www.chrisgreaves.com" and expect to be taken to my blog, but end up at the same old self-compiled home page.
In both cases if I type in "www.chrisgreaves.com/index.htm" I am taken to the superb new WordPress blog site.

I have previously managed to do a redirect from an inferior page, but have not tried a redirect of the entire web site before. Is there some special trick?

Oh, hang on and don't reply yet; maybe I should exit FireFox and flush my cache ....

(Minutes later:)
Tada! :fanfare: Thanks Leif!!!!
There's nothing heavier than an empty water bottle

User avatar
Leif
Administrator
Posts: 7207
Joined: 15 Jan 2010, 22:52
Location: Middle of England

Re: Open Blog from Web Address

Post by Leif »

Have you got anything else on your index.htm page?

If someone visits your site with scripting disabled, they will typically see something like this:
x.jpg
(as seen in my Firefox on an otherwise totally blank page).

You may wish to add a more friendly, manual link, such as Click here to continue... (although it is possible just to click the link shown in the attachment).
You do not have the required permissions to view the files attached to this post.
Leif

User avatar
ChrisGreaves
PlutoniumLounger
Posts: 15576
Joined: 24 Jan 2010, 23:23
Location: brings.slot.perky

Re: Open Blog from Web Address

Post by ChrisGreaves »

Leif wrote:You may wish to add a more friendly, manual link,
Thanks Leif.
Method 1, slightly adjusted, should do the trick then

Code: Select all

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Chris Greaves's Home page</title>
<meta http-equiv="REFRESH" content="3;url=http://www.chrisgreaves.com/WP/"></HEAD>
<BODY>
I have moved to a WordPress fabrication at 
<p class="Normal"><a class="nav" href= "http://www.chrisgreaves.com/WP/"> http://www.chrisgreaves.com/WP/ </a></p>.
</BODY>
</HTML>
I have set in place a 3-second delay, which I will remove later today.
I remember being puzzled about pages which said "You will be redirected shortly" instead of just getting on with the job.
There's nothing heavier than an empty water bottle

User avatar
Leif
Administrator
Posts: 7207
Joined: 15 Jan 2010, 22:52
Location: Middle of England

Re: Open Blog from Web Address

Post by Leif »

That works OK!

Just as a matter of interest, what do you have in http://www.chrisgreaves.com/WP/ ?

Is it not something you can put in the root folder of your domain (i.e. http://www.chrisgreaves.com/" onclick="window.open(this.href);return false;)?
Leif

User avatar
ChrisGreaves
PlutoniumLounger
Posts: 15576
Joined: 24 Jan 2010, 23:23
Location: brings.slot.perky

Re: Open Blog from Web Address

Post by ChrisGreaves »

Leif wrote:That works OK!
Thanks Leif greatly for the confirmation, and the initial nudge.
Just as a matter of interest, what do you have in http://www.chrisgreaves.com/WP/ ? Is it not something you can put in the root folder of your domain (i.e. http://www.chrisgreaves.com/" onclick="window.open(this.href);return false;)?
Now you are going to confuse me (grin)
For the longest time http://www.chrisGreaves.com/index.htm" onclick="window.open(this.href);return false; has been my home page, originally with about 740 pages hanging off it via a site map.
This week I got tired of my home-grown compiler and decided to join the human race, switched to Word Press after experimenting briefly with Google Sites.

So right now (Friday morning) I am ecstatic that if a CEO/CFO wanders off to ChrisGreaves.com, they'll see professional-looking glossy instead of nerdy-geek-triumphal bytes.

I still have to clean up http://www.chrisgreaves.com/WP/" onclick="window.open(this.href);return false;, make it look less like a blog and more like a web site, and, as you suggest, make it the home page, avoiding redirection.

I am doing this in little steps in my Copious Free Time(TM) while mastering Twitter, LinkedIn, an eLetter for CEOs and a blog ditto while sitting on the phone trying to drum up business after accompanying my neighbour to the vets with her aging cat. :exhausted:
There's nothing heavier than an empty water bottle

User avatar
Leif
Administrator
Posts: 7207
Joined: 15 Jan 2010, 22:52
Location: Middle of England

Re: Open Blog from Web Address

Post by Leif »

Good luck with it!

:whisper: I'm not so sure about the 'Chris Revenue' bit though - it brought to mind our own Inland Revenue, followed closely by images of Chris's Revue (:shudder:)...

:grin:
Leif