Walden

So many thanks - you have solved one problem for me. I tried the "float" method and it worked! I then simplified it, for instance cutting out the <DIV> as I didn't need the popup to move around and then removed one table, and it still did what I wanted. Then I followed your "float2" method and, after what seemed at first a step backwards, I worked out what to do and it now works. Wonders!!

I also purchased the book recomended by Joe, but I still do not understand some basics of the syntax.

As a result, I still  have some problems that I cannot solve.

The first is that ondblclick, I am trying to put the value of "num" (1) into AFIELD.007-01. This works fine in IE but not in any other browser.

I am also trying to change the text on some buttons generated by AS/400 Workstation Gateway. This also works in IE but not elsewhere.

I suspect that these are the same problem. When I use Netscape 7.1, it complains that both
document.getElementById("SESSION") and document getElementById(buttons2)
have no properties but I have no idea what this means.. I can believe that it is really very simple.


Do you  or anyone else have a moment to see what I am doing wrong.

I would also like to get rid of the <HR> generated by AS/400 Workstation Gateway as it takes up a lot of space, but, try as I might, I cannot do it.

I have posted below a snip from my code. The button name change won't work with this as there is no "session" value but it works when live in IE only.

If you have a moment, I would much appreciate any help.

best wishes

Rob

_____________________________________________

<html>
<head><title>AS/400 Workstation Gateway</title>
<style>A:link {color:blue;text-decoration:none;font-weight:bold;}
A:visited {color:blue;text-decoration:none;font-weight:bold;}
A:hover {color:blue;text-decoration:underline;font-weight:bold;}</style>
</head>
<body>

<pre>
<center><h3>AS/400 Workstation Gateway</h3></center>
<HR>
<script language="JavaScript"> var num; var msgt; var colour; var session=(document.getElementById('SESSION').value);
javascript:window.history.forward(1); colour = "cyan"; void(document.bgColor='C0C0C0');
function fd() {var buttonname = session + "/BUTTON.999-999=*E"; document.getElementById(buttonname).click()}
function fm(msg) {;
if (msg=='1') {msgt="Double left click on link to navigate"}
else if (msg=='2') {msgt="Double click to continue"}
else if (msg=='3') {msgt="Double click to Navigate or Single click and then select option"}
else if (msg=='4') {msgt="Double click for details or Single click and click on Navigate"}
else {msgt="Hover over highlighted links or images for instructions"}
javascript:document.getElementById('popupText').innerHTML=msgt; }


function fr(num) {document.getElementById('AFIELD.007-016').value = num} </script>
<input type="text" name="AFIELD.007-016" value="" size="64" maxlength="64">
<table><tbody><tr><td bgcolor="YELLOW"> To accept, click on ENTER; else type new ID &amp; click on ENTER </td></tr>
<tr><td bgcolor="yellow" id="popupText"> HOver over highlighted links or images for instructions</td></tr></tbody></table> <br>
<br> <font color="BLACK"> 1<a href="#" onmouseover="fm(2)" ondblclick="fr(1); fd()" onmouseout="fm(9)" ;=""> United Kingdom</a>
<br><br> <br> <br> <br> <br> <br> <br> <br> <br>


<script language="JavaScript" defer="defer">
function cbt2(letter, newText) {var buttons2 = session + "/BUTTON.999-999=*" + letter; document.getElementById(buttons2).value=newText;}
cbt2('1', "Help"); cbt2('2', "MSG Help"); </script>


<input type="submit" name="/BE6E2268F1E1F669/4FD9C6F3/BUTTON.999-999=*E" value="Enter">
<input type="submit" name="/BE6E2268F1E1F669/4FD9C6F3/BUTTON.999-999=*U" value="Page Up">
<input type="submit" name="/BE6E2268F1E1F669/4FD9C6F3/BUTTON.999-999=*V" value="Page Down">
<input type="submit" name="/BE6E2268F1E1F669/4FD9C6F3/BUTTON.999-999=*1" value="F01">
<input type="submit" name="/BE6E2268F1E1F669/4FD9C6F3/BUTTON.999-999=*2" value="F02">
</pre>
</body></html>













Walden H. Leverich wrote:

Rob,

Actually, I just checked with one of the "real" web guys here, and
getElementByID is supported in both IE and NS (and Mozilla and Firefox)
so you don't need any of the script block at the bottom of the example.


http://w3.techsoftwareinc.com/float2.html

Shows a new example w/out the script block. Much simpler that way.

-Walden


------------
Walden H Leverich III
President & CEO
Tech Software
(516) 627-3800 x11
WaldenL@xxxxxxxxxxxxxxx
http://www.TechSoftInc.com


Quiquid latine dictum sit altum viditur.
(Whatever is said in Latin seems profound.)

-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx]
On Behalf Of Rob Dixon
Sent: Friday, 05 November, 2004 04:04
To: Web Enabling the AS400 / iSeries
Subject: Re: [WEB400] Javascript and browser compatability

Walden

Many thanks your further help. You are absolutely right about NS supporting onMouse..., etc.. As I lay in bed last night I suddenly remembered, but, as my createPopup wasn't working, there was no sign that onMouse... was working, so I forgot.


Your sample looks very promising. I won't have much time to look at it

today so it will keep me busy over the weekend.

Once again many thanks for your help.

Rob  Dixon


Walden H. Leverich wrote:



I can't speak for createPopup since I use floating DIVs instead. But


onMouse... and onClick are absolutely supported on current Netscapes, I
can't speak for 4.7x.


Take a look at http://w3.techsoftwareinc.com/float.html (and the source


behind it) and see if it fits your needs. The trick is in the JS at the
bottom of the page which loads up the variable "popup" and "popupText"
correctly depending on which flavor of DOM your browser uses.


-Walden

________________________________

From: web400-bounces@xxxxxxxxxxxx on behalf of Rob Dixon
Sent: Thu 04-Nov-04 6:47 PM
To: Web Enabling the AS400 / iSeries
Subject: Re: [WEB400] Javascript and browser compatability









_______________________________________________ This is the Web Enabling the AS400 / iSeries (WEB400) mailing list To post a message email: WEB400@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/web400 or email: WEB400-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/web400.


_______________________________________________ This is the Web Enabling the AS400 / iSeries (WEB400) mailing list To post a message email: WEB400@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/web400 or email: WEB400-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/web400.






As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.