Eclipse中的新PHP Liferay portlet

时间:2016-02-02 17:31:14

标签: php liferay portlet

我正在尝试使用Eclipse IDE和最新安装的Liferay SDK为Liferay开发一个简单的PHP portlet。

在我创建一个新的" Liferay portlet"我看到一个带有"条目文件的JSP项目"叫" view.jsp"。

我如何自定义它,例如选择" index.php"?

这是默认的portlet.xml文件:

<?xml version="1.0"?>

<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd" version="2.0">
    <portlet>
        <portlet-name>GSI2</portlet-name>
        <display-name>GSI2</display-name>
        <portlet-class>com.liferay.util.bridges.mvc.MVCPortlet</portlet-class>
        <init-param>
            <name>view-template</name>
            <value>/view.jsp</value>
        </init-param>
        <expiration-cache>0</expiration-cache>
        <supports>
            <mime-type>text/html</mime-type>
        </supports>
        <portlet-info>
            <title>GSI2</title>
            <short-title>GSI2</short-title>
            <keywords>GSI2</keywords>
        </portlet-info>
        <security-role-ref>
            <role-name>administrator</role-name>
        </security-role-ref>
        <security-role-ref>
            <role-name>guest</role-name>
        </security-role-ref>
        <security-role-ref>
            <role-name>power-user</role-name>
        </security-role-ref>
        <security-role-ref>
            <role-name>user</role-name>
        </security-role-ref>
    </portlet>
</portlet-app>

当我尝试更改&#34; view.jsp&#34;到&#34; index.php&#34;,我收到消息Path /index.php is not accessible by this portlet

0 个答案:

没有答案