Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 1.7DR#3
-
Component/s: Framework, ICE-Components
-
Labels:None
-
Environment:portal portlet, JSF 1.2, JBoss Portal
Description
Does JSF 1.2 treat client ID's differently? The reason that I ask is that the file upload component is not working in JBoss Portal (which comes with JSF 1.2) but it is working in Liferay (using JSF 1.1).
When I look at the rendered out HTML of the two and compare, it appears that the client ID supplied by the <ice:portlet> tag is rendered all the way down the tree in Liferay. For example, in Liferay the <ice:portlet> renders out to:
...
<div id="_components_fileUpload_WAR_componentshowcase_INSTANCE_mbUk_">
...
and then later, when the iframe for the file upload is rendered, the hidden input that identifies the fileupload section looks like this:
...
<input type="hidden"
name="ice.component"
value="_components_fileUpload_WAR_componentshowcase_INSTANCE_mbUk_:ifSub:iceform:icepnltabset:0:inputFileName"/>
...
Now if we look at exactly the same thing running under JBoss Portal, we get this from the <ice:portlet> tag:
...
<div id="jbpns_2fdefault_2fShowcase_2fFile_20Uploadsnpbj">
...
And this is the hidden input:
<input type="hidden"
name="ice.component"
value="j_id2:ifSub:iceform:icepnltabset:0:inputFileName"/>
So you see that the portlet component's id is not pre-pended. It's generated some default one. The whole thing is failing in our UploadServer where it calls the D2DViewHandler logic in findComponent the result is always "null" and I assume it's because of this ID discrepancy. Anyone able to educate me on why this is?
When I look at the rendered out HTML of the two and compare, it appears that the client ID supplied by the <ice:portlet> tag is rendered all the way down the tree in Liferay. For example, in Liferay the <ice:portlet> renders out to:
...
<div id="_components_fileUpload_WAR_componentshowcase_INSTANCE_mbUk_">
...
and then later, when the iframe for the file upload is rendered, the hidden input that identifies the fileupload section looks like this:
...
<input type="hidden"
name="ice.component"
value="_components_fileUpload_WAR_componentshowcase_INSTANCE_mbUk_:ifSub:iceform:icepnltabset:0:inputFileName"/>
...
Now if we look at exactly the same thing running under JBoss Portal, we get this from the <ice:portlet> tag:
...
<div id="jbpns_2fdefault_2fShowcase_2fFile_20Uploadsnpbj">
...
And this is the hidden input:
<input type="hidden"
name="ice.component"
value="j_id2:ifSub:iceform:icepnltabset:0:inputFileName"/>
So you see that the portlet component's id is not pre-pended. It's generated some default one. The whole thing is failing in our UploadServer where it calls the D2DViewHandler logic in findComponent the result is always "null" and I assume it's because of this ID discrepancy. Anyone able to educate me on why this is?
Activity
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
Assignee | Adnan Durrani [ adnan.durrani ] |
Ken Fyten
made changes -
Fix Version/s | 1.7 [ 10080 ] |
Ken Fyten
made changes -
Fix Version/s | 1.7Beta1 [ 10121 ] | |
Fix Version/s | 1.7 [ 10080 ] |
Deryk Sinotte
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Ken Fyten
made changes -
Assignee | Mark Collette [ mark.collette ] | Adnan Durrani [ adnan.durrani ] |
Ken Fyten
made changes -
Field | Original Value | New Value |
---|---|---|
Environment | portal portlet | portal portlet, JSF 1.2, JBoss Portal |
Fix Version/s | 1.7 [ 10080 ] | |
Assignee | Mark Collette [ mark.collette ] |
Deryk Sinotte
created issue -
Try as I might, I am unable to reproduce this issue so I am going to mark it as fixed. I tried from the head and went back to 1.7 DR3a as well, re-activating the FileUpload portlet and adding the panelBorder back in but no luck. Maybe something we did along the way managed to remove the issue. I'll re-open if it crops up again.