SitePoint Sponsor

User Tag List

Results 1 to 6 of 6

Hybrid View

  1. #1
    SitePoint Addict
    Join Date
    Mar 2003
    Location
    london
    Posts
    222
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    make website homepage

    Hey,
    Whats the code to make people be able to click on a link and make my website their homepage pls?

    Thanks in advance

  2. #2
    SitePoint Addict
    Join Date
    May 2000
    Posts
    313
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Something like this:
    <html>
    <head>
    <title>Home Page/Book Mark</title>
    <script language="JavaScript">
    function bookit()
    {
    if (document.all)
    {
    window.external.AddFavorite(location.href,document.title)
    }
    }
    </script>
    </head>
    <body bgcolor="lightgreen">

    <a href="JavaScript:bookit()">Click here to bookmark this site</a>
    </body>
    </html>

  3. #3
    SitePoint Addict
    Join Date
    Mar 2003
    Location
    london
    Posts
    222
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Isn't that for bookmark...I would like the one to make it the homepage.
    thanks.

  4. #4
    SitePoint Enthusiast Br00klynzzFinEST's Avatar
    Join Date
    Apr 2003
    Location
    Brooklyn
    Posts
    51
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Code:
    <!--[if IE]>
    <font face="Arial" size="3">
    <A HREF="#"
    onClick="this.style.behavior='url(#default#homepage)';
    this.setHomePage('http://www.yoursite.com');">
    Make My Site Your Homepage
    </A>
    </font>
    <![endif]-->
    You can also use images, and change fonts with this example.

  5. #5
    A Smarter Way to Web! zivo's Avatar
    Join Date
    Aug 2003
    Location
    Chicago
    Posts
    433
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    With no onCLick attribute, just HREF?

    Hello - Do you (or anyone!) know how to structure it to not use the onClick attribute and only specify a value for the HREF?

    I ask as I need to incorporate this into a Bar value within the PeopleSoft Enterprise Portal version 8.8, and I can only specify a value for an HREF. I can add JavaScript functions to the header of the page, but I cannot specify any other attributes within the anchor tag.

    Much appreciated!

    mp/m

  6. #6
    SitePoint Addict
    Join Date
    Mar 2003
    Location
    london
    Posts
    222
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thank u


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •