Author: fmeschbe Date: Mon Oct 26 13:39:09 2009 New Revision: 829792 URL: http://svn.apache.org/viewvc?rev=829792&view=rev Log: FELIX-1808 Oh my ... IE6 does not accept event handlers when using dynamic DOM creation ... so we do innerHTML generation and have the browser parse and setup the DOM internally. This works now.
Modified: felix/trunk/webconsole/src/main/resources/res/ui/configmanager.js Modified: felix/trunk/webconsole/src/main/resources/res/ui/configmanager.js URL: http://svn.apache.org/viewvc/felix/trunk/webconsole/src/main/resources/res/ui/configmanager.js?rev=829792&r1=829791&r2=829792&view=diff ============================================================================== --- felix/trunk/webconsole/src/main/resources/res/ui/configmanager.js (original) +++ felix/trunk/webconsole/src/main/resources/res/ui/configmanager.js Mon Oct 26 13:39:09 2009 @@ -153,7 +153,7 @@ trEl.appendChild( tdEl ); // define this TD as innerHTML otherwise the onClick event handler - // of the Delete button is not accepted by IE... + // of the Delete button is not accepted by IE6 (!)... var innerHTML = '<input type="submit" class="submit" name="submit" value="Save" />'; innerHTML += ' '; innerHTML += '<input type="reset" class="submit" name="reset" value="Reset" />'; @@ -300,29 +300,22 @@ if (obj.bundleLocation) { + var form = createElement( "form", null, { + method: "POST", + action: pluginRoot + "/" + obj.pid + }); + + // define this form contents as innerHTML otherwise the onClick + // event handler of the Unbind button is not accepted by IE6 (!)... + var formInner = '<input type="hidden" name="unbind" value="true"/>'; + formInner += '<input type="submit" name="submit" value="Unbind" class="submit" title="Unbind Configuration from Bundle" onClick="return confirmUnbind(\'' + obj.pid + '\', \'' + obj.bundleLocation + '\');"/>'; + form.innerHTML = formInner; + parent.appendChild( tr( "content", null, [ td( "content", null, [ text( " " ) ]), - td( "content", null, [ - createElement( "form", null, { - method: "POST", - action: pluginRoot + "/" + obj.pid - }, [ - createElement( "input", null, { - type: "hidden", - name: "unbind", - value: "true" - }), - createElement( "input", "submit", { - type: "submit", - name: "submit", - value: "Unbind", - title: "Unbind Configuration from Bundle", - onClick: "return confirmUnbind('" + obj.pid + "', '" + obj.bundleLocation + "');" - }) - ]) - ]) + td( "content", null, [ form ] ) ]) ); }