...

View Full Version : Determinining a user's homepage?



KrazyKid
06-19-2002, 02:41 PM
Can you determine the value of a user's homepage?

QuackHead
06-19-2002, 03:06 PM
You mean, can you determine what page the visitor has as their homepage??

whackaxe
06-19-2002, 03:26 PM
if you are looking how to set the users homepage this is a text link that sets it (if someone could tell me how to change that for when the page loads that would be great :D)

<SPAN onClick="this.style.behavior='url(#default#homepage)';this.setHomePage('http://www.wsabstract.com');">Click here to make wsabstract ur home page</SPAN>

QuackHead
06-19-2002, 03:53 PM
Originally posted by whackaxe
(if someone could tell me how to change that for when the page loads that would be great :D)

how about this...

<body onLoad="setHomePage('http://www.wsabstract.com');">

~Quack

KrazyKid
06-19-2002, 04:26 PM
Sorry for not offering a prompt reply..thanks for the suggestions on setting the page..

I want to be able to validate whether or not a user has the correct homepage set incase the page is the same but the URL is different...

jkd
06-19-2002, 07:22 PM
To my knowledge, you cannot read what the user's homepage is, unless they are using IE and you use ActiveX and search through their registry, but they'll (hopefully) get big scary alerts saying why they shouldn't allow the script to run.

You can redirect them to their homepage though:

if (!window.home) window.home = function() { location.href = 'about:home' };

window.home();

QuackHead
06-19-2002, 07:36 PM
sorry, my post didn't apply to the original comment, I was replying to whackaxe's post - but even then, the method I gave was wrong :D

~Quack

KrazyKid
06-19-2002, 08:32 PM
Thanks to all!
I will try to do the registry snoop as it would be in a trusted evironment or an HTA...

whackaxe
06-19-2002, 09:05 PM
is there a shorter way that the way i just showed for setting the homepage. save a couple of lines of code :D

JohnKrutsch
06-19-2002, 10:01 PM
You could try somethign like this for onload:

<body onload="hp.style.behavior='url(#default#homepage)';hp.setHomePage('http://www.uvsc.edu');">
<span id="hp"></span>

although it is highly annoying!



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum