-
1. Re: Why JSF portlet show null
wesleyhales Jun 17, 2009 9:46 AM (in response to uxa)Post your config files, It sounds like your portlet.xml view-param JSF file is wrong.
-
2. Re: Why JSF portlet show null
uxa Jun 18, 2009 11:37 PM (in response to uxa)sorry, this question is solved, thanks
another question is why I deployment portlet, but portlet instance didn't created, I must using admin to create one.
portlet-instance.xml
<instance-id>SimplestHelloWorldInstance</instance-id>
<portlet-ref>SimplestHelloWorld</portlet-ref>
Is anywhere wrong? -
3. Re: Why JSF portlet show null
jpviragine Jun 19, 2009 6:36 AM (in response to uxa)Hi uxa,
Have you created the default-object.xml or something-object.xml?
In your case, the content of the file should be something like:<deployments> <deployment> <parent-ref>default</parent-ref> <if-exists>overwrite</if-exists> <page> <page-name>SimplestHelloWorld</page-name> <display-name>SimplestHelloWorld</display-name> <window> <window-name>SimplestHelloWorldWindow</window-name> <instance-ref>SimplestHelloWorldInstance</instance-ref> <region>center</region> <height>0</height> </window> </page> </deployment> </deployments>
Cheers,
JP -
4. Re: Why JSF portlet show null
uxa Jun 20, 2009 3:36 AM (in response to uxa)Thanks jpviragine
yes, I have the default-object.xml, but I need using admin mode to create the portlet instance for my portlet object.
What I need to do, if I deploy portlet and I want it instance be created. -
5. Re: Why JSF portlet show null
jpviragine Jun 20, 2009 6:27 AM (in response to uxa)Uxa,
As you said that you have created portlet-instances.xml and default-object.xml. I think the problem is in your portlet.xml.
Please, take a look at: http://www.redhat.com/docs/en-US/Enterprise_Portal_Platform/4.3/html/Reference_Guide/descriptors_portlet.html for a correct usage of the three files. -
6. Re: Why JSF portlet show null
uxa Jun 21, 2009 9:28 PM (in response to uxa)my three files is
portlet.xml<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <portlet-app version="1.0" xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"> <portlet> <portlet-name>SimplestHelloWorld</portlet-name> <portlet-class> com.king.SimplestHelloWorldPortlet </portlet-class> <supports> <mime-type>text/html</mime-type> </supports> <portlet-info> <title>Simplest Hello World Portlet</title> </portlet-info> </portlet> </portlet-app>
portlet-instance.xml<?xml version="1.0" standalone="yes"?> <!DOCTYPE deployments PUBLIC "-//JBoss Portal//DTD Portlet Instances 2.6//EN" "http://www.jboss.org/portlet/dtd/portlet-instances_2_6.dtd"> <deployments> <deployment> <instance> <instance-id>SimplestHelloWorldInstance</instance-id> <portlet-ref>SimplestHelloWorld</portlet-ref> </instance> </deployment> </deployments>
default-object.xml<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE deployments PUBLIC "-//JBoss Portal//DTD Portal Object 2.6//EN" "http://www.jboss.org/portal/dtd/portal-object_2_6.dtd"> <deployments> <deployment> <parent-ref>default</parent-ref> <if-exists>overwrite</if-exists> <page> <page-name>SimplestHelloWorld</page-name> <window> <window-name>SimplestHelloWorldWindow</window-name> <content> <content-type>portlet</content-type> <content-uri> SimplestHelloWorldInstance </content-uri> </content> <region>center</region> <height>0</height> </window> </page> </deployment> </deployments>
when I depoly, I can't see portlet instance be created.
my file structure is
SimpleHelloWorld
--MEAT-INF
--WEB-INF
--classes
--com
--king
--SimplestHelloWorldPortlet.class
--css
--images
--lib
--default-object.xml
--jboss-app.xml
--portlet-instance.xml
--portlet.xml
--web.xml
Is anywhere wrong? -
7. Re: Why JSF portlet show null
uxa Jun 21, 2009 9:29 PM (in response to uxa)my three files is
portlet.xml<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <portlet-app version="1.0" xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"> <portlet> <portlet-name>SimplestHelloWorld</portlet-name> <portlet-class> com.king.SimplestHelloWorldPortlet </portlet-class> <supports> <mime-type>text/html</mime-type> </supports> <portlet-info> <title>Simplest Hello World Portlet</title> </portlet-info> </portlet> </portlet-app>
portlet-instance.xml<?xml version="1.0" standalone="yes"?> <!DOCTYPE deployments PUBLIC "-//JBoss Portal//DTD Portlet Instances 2.6//EN" "http://www.jboss.org/portlet/dtd/portlet-instances_2_6.dtd"> <deployments> <deployment> <instance> <instance-id>SimplestHelloWorldInstance</instance-id> <portlet-ref>SimplestHelloWorld</portlet-ref> </instance> </deployment> </deployments>
default-object.xml<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE deployments PUBLIC "-//JBoss Portal//DTD Portal Object 2.6//EN" "http://www.jboss.org/portal/dtd/portal-object_2_6.dtd"> <deployments> <deployment> <parent-ref>default</parent-ref> <if-exists>overwrite</if-exists> <page> <page-name>SimplestHelloWorld</page-name> <window> <window-name>SimplestHelloWorldWindow</window-name> <content> <content-type>portlet</content-type> <content-uri> SimplestHelloWorldInstance </content-uri> </content> <region>center</region> <height>0</height> </window> </page> </deployment> </deployments>
when I depoly, I can't see portlet instance be created.
my file structure isSimpleHelloWorld --MEAT-INF --WEB-INF --classes --com --king --SimplestHelloWorldPortlet.class --css --images --lib --default-object.xml --jboss-app.xml --portlet-instance.xml --portlet.xml --web.xml Is anywhere wrong?
-
8. Re: Why JSF portlet show null
jpviragine Jun 21, 2009 10:38 PM (in response to uxa)uxa,
Change your default-object.xml to:<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE deployments PUBLIC "-//JBoss Portal//DTD Portal Object 2.6//EN" "http://www.jboss.org/portal/dtd/portal-object_2_6.dtd"> <deployments> <deployment> <parent-ref>default</parent-ref> <if-exists>overwrite</if-exists> <page> <page-name>SimplestHelloWorld</page-name> <window> <window-name>SimplestHelloWorldWindow</window-name> <instance-ref>SimplestHelloWorldInstance</instance-ref> <region>center</region> <height>0</height> </window> </page> </deployment> </deployments>
-
9. Re: Why JSF portlet show null
uxa Jun 21, 2009 11:18 PM (in response to uxa)I try to use
<content> <content-type>portlet</content-type> <content-uri> SimplestHelloWorldInstance </content-uri> </content>
or<instance-ref>SimplestHelloWorldInstance</instance-ref>
the result is the same