I came across this writing on Tech Support, and I'm wondering what you guys make out of it. Are IB implying they are in the process of dropping support for W3C standards and implementing legacy functions?
However in WebFOCUS 7.7.xx and higher, there are exposed functions the HTML Composer makes available for the developer to use. The function: IbComposer_enableHtmlElement('ElementID', true/false);
This function would accomplish the same effect as the above code and should be used if the developer is using WebFOCUS 7.7.xx or higher: Change: document.getElementById('agency_code').disabled = false; To: IbComposer_enableHtmlElement('agency_code',false);
The exposed functions will always work when a new release is available.
Any thoughts?This message has been edited. Last edited by: <Kathryn Henning>,
Change: document.getElementById('agency_code').disabled = false; To: IbComposer_enableHtmlElement('agency_code',false);
Gosh, that's not even correct! The second statement does the opposite of the first...
Anyway, getElementById() will always work, regardless of what IBI says. Personally, I would probably use JQuery's $('#agency_code').prop('disabled', false) instead.
The difference is that IBI's implementation does a couple of things for controls they customized, such as comboboxes and arrays of checkboxes or radio buttons. It also behaves a bit differently for Internet Explorer, I think that has to do with old versions (6 or 7 and older).
I do think it's bad design that HTML uses a property disabled=true instead of enabled=false; inverse logic is confusing. BTW, Microsoft does the same in the Advanced Internet Explorer options - it's a common ailment.This message has been edited. Last edited by: Wep5622,
WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010 : Member of User Group Benelux :
September 03, 2014, 07:40 AM
Håkan
I agree, inverse logic is confusing. Anyway, I think I stick to the HTML/Javascript DOM style.
If you don't use our API functions, your code may not work in newer releases and Support will tell you to change to the API functions at that point.
David Glick Director WebFOCUS App Studio and WebFOCUS Developer Studio WebFOCUS Division Information Builders, Inc. Direct (917) 339-5560 Voice Mail (212) 736-6250 x3560 Fax (212) 947-5168 Email david_glick@ibi.com
September 05, 2014, 06:37 AM
Håkan
David, is there ANY kind of documentation on your legacy API functions?
They are not "legacy" API functions. They are documented in the manual like everything else...
David Glick Director WebFOCUS App Studio and WebFOCUS Developer Studio WebFOCUS Division Information Builders, Inc. Direct (917) 339-5560 Voice Mail (212) 736-6250 x3560 Fax (212) 947-5168 Email david_glick@ibi.com
September 05, 2014, 08:51 AM
Håkan
David,
sorry had not seen that section on the 8.08 documentation site.