Title:
you must be overwriting some of DynAPI's reload functionality. wouldnt this be safer?
DynAPI.addResizeFunction('document.location.reload(true)');

Matt Lam wrote:
[EMAIL PROTECTED]">
In fact, I did use 
DynAPI.onResize = function() {
window.location.reload();
}
but that won't solve the problem either. It is working
fine in other browser except NS4.75

I dont know what is going on.

I really need some help :-(



--- Jim Richards <[EMAIL PROTECTED]> wrote:
You can't use

<body onresize="return something();">

because that'll confuse DynAPI, I tend to force a
reload of the page, as
this works best across
all browers

DynAPI.onResize = function() {
window.location.reload();
}


Matt Lam wrote:

Hi,
If I comment out the resize code, this problem will
go
away. But I have to detect the resize event so that
i
can move the dynlayer to the correct position in
the
browser. The problem is it doesn't matter where I
put
the onresize event handler, the problem will occur.
<body onResize=""> no matter what code i put inside
that onResize="" the problem will happen, or if i
do 
DynAPI.onResize = function () {
//doesn't matter what code is in here, the
problem will happen too
}

my code is something like the following:

<HTML><HEAD><TITLE></TITLE>
<Script language="Javascript">
DynAPI.setLibraryPath('/home/dynapi/src/lib/')
DynAPI.include('dynapi.api.*')
DynAPI.include('dynapi.event.*')
DynAPI.include('dynapi.ext.inline.js')
</script>

</head>
<body>

<script language="Javascript">
DynAPI. {
x= DynAPI.document.getAll()['first']
xPos = x.getPageX()
yPos = x.getPageY()
layer1 = new DynLayer()
layer1.setSize(150, 16)
layer1.moveTo(xPos,yPos)
DynAPI.document.addChild(layer1)
layer2 = new DynLayer()
layer2.setSize(150, 16)
layer2.moveTo(xPos, yPos+16)
DynAPI.document.addChild(layer2)
}
</script>

< br><table align="center">
<tr>
<td valign=bottom>
<div id="first" style="position:relative;
left:0px; top:4px; width:125px; height:16px"></div>
</td>
</tr>
</table>
</body>
</html>
Can anyone help plz.

Thanks in advance!


--- Matt Lam <[EMAIL PROTECTED]> wrote:

In the page I have, there are only two DynLayers,
and
there are almost identical. There is no other
DHTML
stuff like DynImage or widget in the page.
I tried many different ways to do it and that
problem
still comes up. Even if I just simply reload the
page
everytime the page is refreshed, that still can't
solve the problem. It is working with other NS
like
NS4.08. 
BTW, the browser I am taking about is NS4.75.
I will try the different ideas Richard mention
again.

Thanks a lot, Richard.

Jack

--- Richard Bennett <[EMAIL PROTECTED]> wrote:

Firstly, does the error also occur if you comment
out the resize code? - if
so it's probably because you have a Dynimage , or

a

widget using one, on the
page.
NS4 has a bug when resizing the page, and to

counter

this DynAPI deletes,
and re-writes all the content to the screen when

you

resize the browser.
DynImages do however still cause an error.

If the error stops when you comment out your

resize

code, you could try
delaying the resize-code using a setTimeout, so

the

layers are only moved
after the browser has had time to re-render them.

If all else fails, simply make NS4 reload the
page
on-resize.

Check the FAQ for more info.

http://dynapi.sourceforge.net/doccenter/index.php?TroubleShooting
Richard
www.richardinfo.com


----- Original Message -----
From: "Song Lin" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, October 17, 2001 8:53 PM
Subject: [Dynapi-Help] Problem with Resize on
Netscape message "Alert, did
not find converter or decoder"


Hi, all
I create an inline layer relative to a <td>,

when

the user resize the

browser, I need to move the layer to a correct

position, something like

layer1.moveTo(DynAPI.document.getWidth()-100,

30).

I put those statements
in

the DynAPI.onResize function. It is working

great

with IE, but I couldn't

get it to work on Netscape, everytime I resize

that page on Netscape 4.*,
it

give me a message "Alert, did not find converter

or decoder" and the page

stops loading.

Anyone had this problem before? Or Anyone knows

how to solve it?

Thanks in advance.

Jack
=== message truncated ===


__________________________________________________
Do You Yahoo!?
Make a great connection at Yahoo! Personals.
http://personals.yahoo.com

_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dynapi-help


--

ANDREW HULL |  software engineer
Nine Dots
416-977-6660 ext.231
Portland . Irvine . San Francisco . Toronto
[EMAIL PROTECTED]




Reply via email to