|
Nathan Andelin wrote:
Wait, wait, wait, wait. You said: "I only insert two (2) things in an HTML page to interface with an RPG program. <RECORD> and {{FIELD}} delimeters. Nothing more."How do you interface with an input field?
The value property.
How do you tell it its length?
The size and maxlength properties.
So you say maxlength={{FIELD}}, or something like it? Meaning that every field that has to be changed in the HTML, you have to define a field and then go into the HTML and replace the flag with a FIELD. Now how can you edit that in DreamWeaver???
No, I mean allowing only numeric keystrokes when entering data. But it's clear there is a LOT more work here than you initially intimated.How do you specify numeric editing?
%editc() BIF in RPG.
How do you do that with a <RECORD> and {{FIELD}} delimiter?How do you change its class when it is in error?
element.className = "error";
How do you create a dropdown?How do you edit THAT with DreamWeaver???
I use an ILE procedure that converts an array into an HTML dropdown.
Again, you have to either go in and futz with tags in such a way that DreamWeaver can no longer render the data, or you have to use JavaScript, which belies your <RECORD> and {{FIELD}} statement.How do you initialize the state of these things based on dynamic data?
Set the value property. When the page is generated, or later through an xmlHTTP response.
It's very basic, but it again flies in the face of your statement that all you do is <RECORD> and {{FIELD}}. What I'm trying to point out is that all but the simplest interaction (basically dumping a bunch of text in tables) requires some pretty sophisticated HTML - much more sophisticated than can be done with <RECORD> and {{FIELD}} tags. When you start using a tagged approach, be it RPG-CGI, your approach, or even JSP, it's hard to do anything but the simple stuff.How do you specify classes for columns?
element.className="class";
And rows?
element.className="class";
How do you change the class for a table cell based on the data?
This is very basic.
In reality, you have your own formatting routines to generate widgets on the fly, you use JavaScript to update elements, and we haven't even gotten to the part where we get the data OUT of the page! ESPECIALLY with Ajax!
JSF addresses these issues, which is why I like it. EGL knows how to work with JSF. In EGL, you create a field. Drop the field on the page, and it is automatically formatted and bound. Or, you specify an EGL field as an attribute to a widget. Again, automatically bound. You can still edit the WYSIWYG screen, even after adding these attributes.
Your screen, once you've added tags, can no longer be edited by DreamWeaver. That's a huge problem!
Anyway, enough. Remember, anything you're generating in HTML, there's a good chance I did it a long time ago. I don't just generate HTML. My tools generate JSPs with embedded JavaScript that in turn generate HTML. I know of which I speak <smile>.
Joe
As an Amazon Associate we earn from qualifying purchases.
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.