Hi All,
I have the below code which worked as what I want on Firefox, but the code did not work on IE6. Do you guys have any suggestion for me how to fix the code below to make it work on IE? Thank you for any help in advance. -
<!-- saved from url=(0014)about:internet -->
-
<html>
-
<head><title>Test</title>
-
<script type="text/javascript">
-
<!--
-
function printPage(){
-
var content;
-
content = document.body.innerHTML;
-
content = '<h1>Test</h1>';
-
display(content);
-
}
-
-
function display(content) {
-
top.consoleRef=window.open('','myconsole','width=800,height=500,status=0,scrollbars=1,resizable=1,menubar=1,toolbar=1')
-
top.consoleRef.document.writeln('\<!-- saved from url=(0014)about:internet --\>');
-
top.consoleRef.document.writeln('<html><head><title>My Document</title>'
-
+ '<STYLE TYPE="text/css">'
-
+ ' H1 '
-
+ ' {'
-
+ ' font-family: Arial, Helvetica, sans-serif;'
-
+ ' font-size: 16px;'
-
+ ' font-style: normal;'
-
+ ' font-weight: bolder;'
-
+ ' font-variant: normal;'
-
+ ' color: White;'
-
+ ' text-align: center;'
-
+ ' text-transform: capitalize;'
-
+ ' height: 20px;'
-
+ ' background-color : #638eb9;'
-
+ ' }'
-
+ ' </STYLE> '
-
+ ' </head>'
-
+ ' <body bgcolor=white onLoad="self.focus();window.print()">'
-
+ content
-
+ '</body></html>'
-
)
-
top.consoleRef.document.close()
-
}
-
-->
-
</script>
-
</head>
-
<body>
-
<a NAME="PRINT" HREF="javascript:printPage()"><font size="2">Click For Printable Document</font></a>
-
</body>
-
</html>
-
1 1832 acoder 16,027
Recognized Expert Moderator MVP
What part doesn't work in IE6? Is it just the printing part?
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Jake j |
last post by:
To those of you who sent me working examples of js include routines,
much thanks. I see from them examples that what I'm trying to get to
requires a higher level of js knowledge than I've got. Here's what I'm
really trying to do:
I've been using a sliding banner javascript routine in several html
files and it works fine. Rather than duplicate the code in each file,
however, it would obviously be preferable to including the routine in...
|
by: moondaddy |
last post by:
I want to dynamically create a JavaScript file and cache it on the client
for re-use. I know how to write javascript to a web page from the code
behind, but I don't know how to actually create a file such as
MyNewScript.js and then cache that on the client so all the pages of that
session can use it. Can this be done?
Thanks
--
moondaddy@nospam.com
|
by: Danny |
last post by:
Hello:
I would like to develop a browser extension, or whatever such a thing
is classified as, that would allow a user of IE6, and possibly IE7,
to
switch between a live and development page.
I'm sure the individuals reading this are familiar with what I'm
referring to; however, I'll provide an example.
|
by: Santander |
last post by:
how to decode HTML pages encoded like this:
http://www.long2consulting.com/seeinaction2008/Simplicity_Beach_table/index.htm
Is there script that will do this automatically and generate normal fully
readable HTML?
Santander
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
| |
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
| |
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |