-
FEATURED COMPONENTS
First time here? Check out the FAQ!
After migrating from ZK version 8.5.0 to 8.6.0.1, we faced the issue with Combobox elements only in IE browser. By some reason, it can't be re-created in ZK fiddle, so let me just paste my small demo code here to be clear. Simple ZUL with combobox element:
<zk>
<div apply="org.zkoss.bind.BindComposer" height="278px" width="443px"
viewModel="@id('vm') @init('com.swissre.cre.presentation.mvc.TestModel')">
<combobox id="cmbColor" width="150px"
model="@load(vm.names)" selectedItem="@bind(vm.iname)">
</combobox>
</div>
</zk>
My test model:
public class TestModel {
private String iname;
private List<String> names = Arrays.asList("Iüvanov", "alex", "ivan");
@Init
public void init() {
setIname("Iüvanov");
}
public List<String> getNames() {
return names;
}
public void setNames(List<String> names) {
this.names = names;
}
public String getIname() {
return iname;
}
public void setIname(String iname) {
this.iname = iname;
}
}
If the selected value contains characters like this "ü" (or any other diaeresis characters), the dropdown will be triggered on page re-load (on F5 for instance). If you remove this char from collection element it will not happen. Maybe someone can help me to fix this issue for IE? Thank you in advance.
If the problem doesn't happen on ZK fiddle (assuming you picked the correct version) then, there could be a configuration issue with character encoding in your environment.
Also your explanation
the dropdown will be triggered on page re-load
isn't fully clear. (trigger=open? on the same page or new reloaded page? does it prevent reloading he page?). I'll increase your karma, so that you can post a screenshot describing what you mean.
Also in this case the raw page response might give additional hints especially if character encoding is involved or not. Comparing a working and non working page may just give the missing hint to start some dedicated debugging.
Thank you for your reply.
Sorry for confusing. "trigger=open?" - yes, it opens aoutomaticaly on page re-load.
I'll increase your karma, so that you can post a screenshot describing what you mean. - It will be hard to explain with single screenshot. Maybe you can fallow this link?
https://github.com/zkoss/zk/issues/1874
I posted a .gif with the issue there.
Here is the picture with comparing two HTML result pages:
thanks for the screenshot:
at least it shows 1 maybe relevant difference between your code and anything we can test, or zkfiddle.
Your combobox is using a custom client side widget class crew.inp.CrewCombobox
That's something we can't test without the custom JS code. Can you please try disabling the widget customization to see whether the default implementation zul.inp.Combobox
has the same error. (disabling component customization is usually done in a lang-addon.xml inside your project. There you should find a component definition for combobox defining a custom widget-class
).
If it works as during our tests, then you'll have to debug your custom widget class. Or contact our support in case you can't share the custom code in public.
Thank you for your answer.
I've found the overriding component in lang-addon.xml
I was completely sure that I'm using native ZK element. I'll try to find out if this is due our ovirreded methods in combobox.
I'm a new guy in ZK :) Sorry.
Hello,
Still no luck with this problem. This is true, we use our own CrewDropdown element with some additional functional and style, but I couldn't find any code which might affect the element.
I've found old IE10/IE11 bug - https://answers.microsoft.com/en-us/ie/forum/all/ie-10-11-input-elements-with-unicode-entity/de997de8-3e94-44b8-b7e3-c5291a87c920 And fix for it from ZK developers - https://tracker.zkoss.org/browse/ZK-3183 This is exactly my case, but I have no idea why this fix has stop working in 8.6.0.1 but worked in 8.5.0.
Best Regards.
the code fixing the issue ZK-3183 is still in place, even in 8.6.0.1 https://github.com/zkoss/zk/blob/v8.6.0.1/zul/src/archive/web/js/zul/inp/InputWidget.js#L827-L835
cor3000 ( 2020-03-04 10:01:22 +0800 )editAsked: 2020-02-11 19:50:43 +0800
Seen: 17 times
Last updated: Mar 03 '20