Your Guide to Professional
Web Site Design and Development

• HTML Tips
• HTML Codes
• Web Development
• Web Design Tips
• JavaScript Codes
• 216 Web Safe Colors
• CSS Tutorial
• JavaScript Tutorial
•
ASCII Character Codes

Offering a guide to professional web site design, web page design and web design guidelines

| Web Site Development | HTML Codes | HTML Tips | Web Design Tips | Javascript Snippets | 216 Safe Colors | Symbols | CSS Tutorial | JavaScript Tutorial |

Creating a Print Web Page Button


If you are looking for a way to create a print web page button for your web site, this tip is for you.

You can enable your visitors to print out your web page using JavaScript.

Place the following JavaScript code within your HTML code where you would like the button to appear:


<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
if (window.print) {
document.write('<form>'
+ '<input type="button" name="print" value="Print This Page" '
+ 'onClick="javascript:window.print()"></form>');
}
// End -->
</SCRIPT>

Change the text indicated in red to the text that should appear on your print web page button.

If you publish content, such as articles on your web site, this print page button will provide a great way to enable your visitors to print your content.

 More Web Design Tips