Click to See Complete Forum and Search --> : bookmark
chris9902
08-17-2003, 06:50 PM
i am sure i have seen 1 line scripts that bookmark the page you are on.
if anyone has scripts that
Print page
Bookmark / add to favorites
go back 1
set as homepage
i would be really greatful if you could post them for me
thank you:)
#1: window.print();
#2: IE only - window.external.AddFavorite("http://www.infinitypages.com","Infinity Web Design");
#3: history.go(-1);
#4: IE only - <script type="text/javascript">
function setPage() {
if (!hp.isHomePage("http://www.infinitypages.com"))
hp.setHomePage("http://www.infinitypages.com");
}
</script>
</head>
<body>
<span id="hp" style="behavior:url(#default#homepage)"></span>
<a href="#" onclick="setPage(); return false;">Set Homepage</a>
chris9902
08-17-2003, 07:09 PM
one last thing
do i add window.print(); like this<a href="window.print();">
Use this, as it won't work for those without javascript enabled anyway:
document.write ('<a href="#" onclick="window.print(); return false;">Print</a>');
chris9902
08-18-2003, 05:45 PM
the add to fav thing
how do i make it so when someone clicks text it does it not when the page loads
Like this:
<a href="how_to_add_to_favorites.htm" onclick="window.external.AddFavorite('http://www.infinitypages.com','Infinity Web Design'); return false;">Add to Favorites</a> and the page how_to_add_to_favorites.htm is what those without JS will get...