-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi,
If set up a fileupload on the onClick trigger of a button in one of the forms in my application. When I click in the 'Examine' button a popup window appears to inform me that
Invalid ID: z_ma_l3!iframe. Cause: reserved words not allowed: [arg, page, session, event, spaceOwner, desktop, self]
11-dic-2008 9:34:53 org.zkoss.zk.ui.impl.UiEngineImpl handleError:1107
The whole trace reads
Invalid ID: z_ma_l3!iframe. Cause: reserved words not allowed: [arg, page, session, event, spaceOwner, desktop, self]
11-dic-2008 9:34:53 org.zkoss.zk.ui.impl.UiEngineImpl handleError:1107
GRAVE: >>org.zkoss.zk.ui.UiException: Invalid ID: z_ma_l3!iframe. Cause: reserved words not allowed: [arg, page, session
, event, spaceOwner, desktop, self]
>> at org.zkoss.zk.ui.AbstractComponent.setId(AbstractComponent.java:612)
>> at sun.reflect.GeneratedMethodAccessor27.invoke(Unknown Source)
>> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:597)
>> at org.zkoss.zk.ui.metainfo.Property.assign0(Property.java:260)
>> at org.zkoss.zk.ui.metainfo.Property.assign(Property.java:175)
>> at org.zkoss.zk.ui.metainfo.ComponentInfo.applyProperties(ComponentInfo.java:733)
>> at org.zkoss.zk.ui.impl.AbstractUiFactory.newComponent(AbstractUiFactory.java:95)
>>...
At first I thought it could be due to some error in my form or script, but I tried to copy the following from the online demo (which of course works perfectly) and insert it into my form:
<button label="Upload"> <attribute name="onClick">{ Object media = Fileupload.get(); if (media instanceof org.zkoss.util.media.Media[]) { org.zkoss.util.media.Media[] medias = (org.zkoss.util.media.Media [])media; for (int i = 0; i < medias.length; i++) { Image image = new Image(); image.setContent(medias<i >); image.setParent(pics); } } else if (media != null) Messagebox.show("Not an image: "+media, "Error", Messagebox.OK, Messagebox.ERROR); }</attribute> </button>
The result was the same. If I switch back to zk3.5.1 everything works fine.
I guess the reason for this must lie on the differences between my environment and that of the server running the demo. I'm using the maven jetty plugin 6.1.11 and have the following zk.xml configuration:
<zk> <listener> <description>ThreadLocal Synchronization Listener</description> <listener-class>org.zkoss.zkplus.util.ThreadLocalListener</listener-class> </listener> <preference> <name>ThreadLocal</name> <value>org.springframework.security.context.ThreadLocalSecurityContextHolderStrategy=contextHolder</value> </preference> </zk>
With kind regards
César Varona
Hi cvarona,
please download ZK 3.5.2 again, it should be OK.
Hi cvarona,
when I deployed my initial setup of the ZK 3.5.1 demo i ran into the same errors. I sent a bugreport via email to the developers, cause the demo at zkoss showed the same error. Download the 3.5.2-bin file for development and remove the old files and everything will work.
(Unfortunately my database-connection with hSLQdb does not...)
Steffen
Hello !
I just downloaded 3.5.2 and updated my WEB-INF/lib.
All files are dated 12/08/2008 so I am sure to have all files really updated.
I cleaned my "Module Work Directory" (tomcat 6.0.10).
A simple
zul..... <button id="upload" label="upload" image="/img/attachment.gif"/> controller..... public void onClick$upload(Event ev) { System.out.println("upload event"); byte[] buffer = new byte[0]; try { Media media[] = Fileupload.get("Please select up to 3 files to upload.", "Upload", 3, true); .....
traps with the following exception:
12.12.2008 10:31:37 org.zkoss.zk.ui.metainfo.Property assign:177 SCHWERWIEGEND: Failed to assign [id=${self.parent.uuid}!iframe] to <Iframe z_vp_421> Invalid ID: z_vp_221!iframe. Cause: reserved words not allowed: [arg, page, session, event, spaceOwner, desktop, self] 12.12.2008 10:31:37 org.zkoss.zk.ui.impl.UiEngineImpl handleError:1107 SCHWERWIEGEND: >>org.zkoss.zk.ui.UiException: Invalid ID: z_vp_221!iframe. Cause: reserved words not allowed: [arg, page, session, event, spaceOwner, desktop, self] >> at org.zkoss.zk.ui.AbstractComponent.setId(AbstractComponent.java:612) >> at sun.reflect.GeneratedMethodAccessor31.invoke(Unknown Source) >> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at org.zkoss.zk.ui.metainfo.Property.assign0(Property.java:260) >> at org.zkoss.zk.ui.metainfo.Property.assign(Property.java:175) >> at org.zkoss.zk.ui.metainfo.ComponentInfo.applyProperties(ComponentInfo.java:733) >> at org.zkoss.zk.ui.impl.AbstractUiFactory.newComponent(AbstractUiFactory.java:95) >>...
none of my ids/vars are named arg, page, session, event, spaceOwner, desktop, self.
Please Help!
Thanks in advance
/Horst
ZK3.5.2 had updated, the newest version was realese at 2008-12-09 01:50
2008-12-09 01:50 24,397,824 zk-bin-3.5.2.zip
md5sum of zk-bin-3.5.2.zip:
785bd782ccdc534f9504c5429c07a837 *zk-bin-3.5.2.zip
so, you need download it again.
Yes ! you are right ! I just tried and now it works !
The strange thing is that my first download of 3.5.2 was today an hour ago and is dated 12/08/2008!
The second a few minutes ago is 12/09/2008.
I think I do not have to understand this!
Thanks !
/Horst
Asked: 2008-12-11 08:39:14 +0800
Seen: 533 times
Last updated: Dec 12 '08