E-mail this, printer friendly, top most, etc

M

MI

Hi! I would like to learn to how add some features to my site, such as "e-mail this to a friend", "printer friendly", "topmost articles" and "bookmark this page". Thanks.
 
J

Jim Buyens

-----Original Message-----
Hi!
Howdy.

I would like to learn to how add some features to my
site, such as
"e-mail this to a friend"

Generally, you would write an ASP page that when it first
loads:

o Saves a property called
Request.ServerVariables("HTTP_REFERRER") in a session
variable or hidden form field.
o Displays an HTML form with two text boxes and a Submit
button.
o One text box is for the visitor's e-mail address.
o The other text box is for the friend's e-mail address.
o The Submit button sends the mail.

The code that actually sends the mail would use the
CDO.Message object. This object has a method named
CreateMHTMLBody that can convert a Web page into an HTML-
formatted e-mail message.

For more information about the CreateMHTMLBody method of
the CDO.Message object, browse:

http://msdn.microsoft.com/library/en-
us/cdosys/html/_cdosys_imessage_createmhtmlbody.asp
"printer friendly"

Please browse:

Creating "Printer Friendly" Pages
http://www.interlacken.com/winnt/tips/tipshow.aspx?tip=33
"topmost articles"

Define "topmost". If you mean "most popular", check out
the FrontPage Top Ten List component. To insert one of
these:

1. Choose Web component from the Insert menu.
2. Choose Top 10 List in the Component Type box at
the left.
3. Choose Visited Pages in the Choose A Usage List
box at the right.
4. Click Finish, review the proposed settings, and
click OK.

Note that for this to work, you must have a FrontPage-
extended Web site, and you must activate Usage Reporting
as described at:

Usage Reports Are Empty
http://www.interlacken.com/winnt/tips/tipshow.aspx?tip=30

If you want something more elaborate, you'll have to find
some other way of getting hit counts, sorting them, and
using the results to display a list of pages in
decreasing hit count order.
"bookmark this page"

Add this script to the body of your Web page.

<script>
if (navigator.appName.substring(0,9) == "Microsoft"){
document.write("<p><a href='" +
"javascript:window.external.addFavorite" +
"(document.location,document.title)'>" +
"Bookmark this page.</a></p>")
}
</script>

However, this only works for IE. In any other browser, it
displays nothing and does nothing.

Jim Buyens
Microsoft FrontPage MVP
http://www.interlacken.com
Author of:
*----------------------------------------------------
|\---------------------------------------------------
|| Microsoft Office FrontPage 2003 Inside Out
||---------------------------------------------------
|| Web Database Development Step by Step .NET Edition
|| Microsoft FrontPage Version 2002 Inside Out
|| Faster Smarter Beginning Programming
|| (All from Microsoft Press)
|/---------------------------------------------------
*----------------------------------------------------
 
M

MI

Thanks for your help. Netscape users will be able to open the .mhtml files that I create?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top