Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 405
  • Last Modified:

Problem with DHTML print template in IE 6 version 6.0.2800

Hello All,

I'm having a strange problem wonder if anyone can help, I
have some code which display a dynamic page in a print
template which works fine on my machine running IE with
version 6.0.2600, but as soon as I move to a different
machine running a slightly newer version of the browser
it seems to display the print template but the content
isn't pulled in anymore. The code is as follows:

<HTML XMLNS:IE>
<HEAD>
<IMPORT NAMESPACE="IE" IMPLEMENTATION="#default">

<STYLE TYPE="text/css">
..masterstyle
{
    width:21cm;
    height:29.7cm;
    background:white;  
      border-left:1 solid black;
      border-top:1 solid black;
      border-right:4 solid black;
      border-bottom:4 solid black;
    margin:10px;
}
..contentstyle
{
  width:17.0cm;
  height:26.0cm;
  margin:1.8cm;
  background:white;  
  border:1 dashed gray;
}
</STYLE>

</HEAD>

<SCRIPT LANGUAGE="JavaScript">
<!-- data.php<?=$url_string?>
var lastPage = 1;

function addFirstPage() {
  newHTML  = "<IE:DEVICERECT ID='devicerect1'
MEDIA='print' CLASS='masterstyle'>";
  newHTML += "<IE:LAYOUTRECT ID='layoutrect1'
CONTENTSRC='data.txt' ONLAYOUTCOMPLETE='onPageComplete()'
NEXTRECT='layoutrect2' CLASS='contentstyle'/>";
  newHTML += "</IE:DEVICERECT>";

  devicecontainer.insertAdjacentHTML("afterBegin",
newHTML);
}

function onPageComplete() {
  if (event.contentOverflow) {
    document.all("layoutrect" +
lastPage).onlayoutcomplete = null;
    newHTML  = "<IE:DEVICERECT ID='devicerect" +
(lastPage + 1) + "'MEDIA='print' CLASS='masterstyle'>";
    newHTML += "<IE:LAYOUTRECT ID='layoutrect" +
(lastPage + 1) + "' ONLAYOUTCOMPLETE='onPageComplete()'
NEXTRECT='layoutrect" + (lastPage + 2) + "'  
CLASS='contentstyle'/>";
    newHTML += "</IE:DEVICERECT>";

    devicecontainer.insertAdjacentHTML("beforeEnd",
newHTML);
    lastPage++;
  }
}
// -->
</SCRIPT>

<BODY ONLOAD="addFirstPage()">

<DIV ID="devicecontainer">
<!-- Pages created on the fly go here. -->
</DIV>

</BODY>
</HTML>

I think theres either a bug in the newer versions of IE
or something has changed.

Any help is appreciated.

Pod Mighster.
0
pod_mighster
Asked:
pod_mighster
  • 4
  • 3
  • 3
  • +2
1 Solution
 
VincentPugliaCommented:
Hi,

  check http://msdn.microsoft.com for bugs

Vinny
0
 
pod_mighsterAuthor Commented:
Hello Vinny,

Sorry about the delay, I've had a look on their site can't find anything about IE6 service pack 1 bugs, but that doesn't mean its isn't there :). The site tends to be out of date has information on eariler browsers.

I have now narrowed the problem down to this command
CONTENTSRC='data.txt'

It's really annoying this problem as I had it all working,

Any further suggestion are appreciated.

Cheers.

Pod Mighster.
0
 
VincentPugliaCommented:
Hi,

   Are the paths the same on both machines?  I'm presuming you are on an intranet. -- perhaps the paths/drives are different from one machine to the other.

Vinny
0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
pod_mighsterAuthor Commented:
Hi,

Well...

I don't think its a path problem as I had an earlier version of IE on my machine which the scripts worked with, then I upgraded to latest browser and then the contents stop being displayed.
 
Pod.
0
 
VincentPugliaCommented:
Sorry pod,

   out of ideas.  if I get a chance I'll see if I can find anything with search.

Vinny
0
 
VincentPugliaCommented:
actually, there's a forum at msdn.  You might try posting there
0
 
pod_mighsterAuthor Commented:
Thanks for your help anyways,

I've tried posting on the msdn forum, not been successful - (plus im now being spammed to death by microsoft).

but anyways, i've tried email the guy that came up with the orginal example of how its done, see if he has any ideas.

Thanks again for your help.

Pod.
0
 
Asta CuCommented:
Please finalize this or update us with what else is needed (since much time has passed since last update). If one expert helped you, choose that comment to convert it to the accepted answer and flow points to close this. If more than one expert helped you, choose the Split Points option to share the points among experts you choose. Your feedback is integral and appreciated. If you need special handling help, please make that request in the Community Support topic area, and include this question's URL (link).  The Community Support topic area link is:  http://www.experts-exchange.com/Community_Support/

Recommend checking with WindowsUpdate for a Critical Security Patch announced today. Details here:
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/security/bulletin/ms04-004.asp

Thanks,
Asta
0
 
Asta CuCommented:
pod_mighster,
No comment has been added lately (15 days), so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area for this question:

RECOMMENDATION: PAQ/No Refund

Please leave any comments here within 4 days.

-- Please DO NOT accept this comment as an answer ! --


Thanks,
astaec
EE Cleanup Volunteer
0
 
PashaModCommented:
PAQed - no points refunded (of 250)

PashaMod
Community Support Moderator
0
 
trentbrubakerCommented:
I am having this issue too so BUMP.
0
 
Asta CuCommented:
Hi, trentbrubaker.  Since this question has been closed and moved to our PAQ, recommend posting a new question to draw current attention and include as much about your environment as you can as well as sample links (if applicable).  Include the OS and version as well as the Browser and version in your new question to expedite the process for you and get the solution, and please remain active in your question so it can be brought to an excellent conclusion in the collaboration process.
Thanks, and thanks also to PashaMod for helping on the cleanup effort for questions which are not finalized by askers.
Asta
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 4
  • 3
  • 3
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now