× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




www.jquery.com stuff is free.




Michael Schutte
Admin Professional





"Bob P. Roche"
<BRoche@packaging
corp.com> To
Sent by: Web Enabling the AS400 / iSeries
web400-bounces@mi <web400@xxxxxxxxxxxx>
drange.com cc

Subject
12/31/2008 11:59 Re: [WEB400] AJAX issue in IE
AM


Please respond to
Web Enabling the
AS400 / iSeries
<web400@midrange.
com>






I am very new to javascript and web programming. I have done some basic
pages using CGIDEV2 to build the pages, but, this is my first real foray
into ajax and extensive javascript. I did look at EXTJS, but my limited
(read none) knowledge of javascript made it hard to understand how to use.
I will look into DOJO, EXTJS and PROTTYPEJS further. I did try a demo of
Valence which uses EXTJS, and returns JASON, and ti was much easier to
work with, compared to coding by hand.

Since there is no budget for software, and the update sounded simple I
thought I'd learn some javascript and learn how AJAX works. Now I know its
more IE then my code. As i said I was basing it on Aaron Bartell's article
in IBM systems mag, adn was able to duplicate his sample in my own
program. Being a green screen coder I didn't know it was not available in
IE to just replace the options and not the whole select group. Thanks for
that very important piece of information.



From:
"Walden H. Leverich" <WaldenL@xxxxxxxxxxxxxxx>
To:
"Web Enabling the AS400 / iSeries" <web400@xxxxxxxxxxxx>
Date:
12/31/2008 10:35 AM
Subject:
Re: [WEB400] AJAX issue in IE
Sent by:
web400-bounces@xxxxxxxxxxxx



You can't get there from here. It's a known issue that you cannot set
the innerHtml on a select in IE and have it do what you want. Like it?
Nope. But there it is, deal with it. :-)

Options:

1 (Recommended): Return the <select> part too from the Ajax call and
wrap the select in a span and set the span's innerHtml, works fine.

2: Return just the <option> part, and wrap it up in a select in JS and
then see option #1.

3: Return the items you want in JSON, or other non-html format, and use
the .Add method to add the options to the select tag

Also... Why on earth are you not using a toolkit? If you take option 1
(my recommendation) and had prototype.js as your toolkit your entire
code could (from the <script> to the </script>) be replaced with:

function updDropDown(fldName) {
Ajax.Updater('shiptospan',
'/cgi-bro/SYG930?DDMODE=S&DDVIEWNAME=CB01HP&DDFLDNAME=BTCD&DDDEFAULT='
+ $F('fldName'));
}

where 'shiptpspan' is the id of the span you wrap the shipto select in,
and it would be x-browser to boot.

-Walden

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

Quiquid latine dictum sit altum viditur.
(Whatever is said in Latin seems profound.)
--
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.