You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by Ja...@ict.nl on 2002/03/14 11:39:37 UTC

Re: problem installing HellowWorldPortlet



Jasper van den Bergh,

Please post this on the mailing list so others can benefit.

Where is the file addtopic.jsp?  If the file is under
<jetspeed_home>/WEB-INF, then it can not be referenced directly.

Options:
o Place addtopic.jsp in place that is directly accessible, i.e.
   <tomcat_home>/webapps/ROOT. Now the user is outside of the
   portal environment

o Place addtopic.jsp in place that is directly accessible, i.e.
   <tomcat_home>/webapps/ROOT and reference add attribute
   "target='_blank'" to force the addtopic to be place in a popup
   window. Now the user is outside of the portal environment and
   you have to manage the popup window.

o Place addtopic.jsp in a portlet, place the portlet in a group page,
   and link to the group page.  I recommend this approach
   From local-portlets
      <portlet-entry name="Forum_AddTopic" hidden="false" type="ref"
          parent="JSP" application="false">
          <meta-info>
              <title>ForumAddTopic</title>
              <description>Add a topic to the Forum Portlet</description>
          </meta-info>
          <parameter name="template"
              value="forum/addtopic.jsp" hidden="false"/>
          <media-type ref="html"/>
      </portlet-entry>

    From the "forum" group "add" PSML file
(<jetspeed_home>/WEB-INF/psml/group/forum/html/add.psml):
     <entry parent="Forum_AddTopic">

   The link:
     http://localhost/jetspeed/portal/group/forum/page/add

   As an example see the news page in the apache group that is part
   of jetspeed.
       http://localhost/jetspeed/portal/group/apache/page/news


Jasper.van.den.Bergh@ict.nl wrote:

>
>
> Hello Paul,
>
> I came across this discussion thread and I hope you don't mind me emailing
you,
> but I have a question that I hope you can answer for me.
>
> I have a little JSP project consisting of 7 .JSP files that I want to use in
> Jetspeed (it's a simple discussion forum). I have copied those 7 files into
the
> <jetspeed_home>/WEB-INF/templates/jsp/portlets/html/forum> directory.
> Then I edited the demo-portlets.xreg file and added the following lines
>
>     <portlet-entry name="Forum_JSP" hidden="false" type="ref"
>         parent="JSP" application="false">
>         <meta-info>
>             <title>ForumJSP</title>
>             <description>JSP Forum Portlet</description>
>         </meta-info>
>         <parameter name="template"
>             value="forum/index.jsp" hidden="false"/>
>         <media-type ref="html"/>
>     </portlet-entry>
>
> Then I've added the portlet to the Jetspeed portal and I can see the index.jsp
> page. So far so good. Now, on the index.jsp there is a link to another .JSP
page
>  (addtopic.jsp) but when I click on it Tomcat gives a 404 Not Found error.
>
> Can you tell me what I must do to get this to work? I would greatly appreciate
> your help.
>
> Regards,
> Jasper van den Bergh
> ICT
> Netherlands
>
> -------------------------------
>
>
>>>(2) How do we write .jsp portlets???  because I see a JSP Hello World
>>>portlet which comes with Jetspeed.  Looks to me there is a class file for
>>>that, so is that really a JSP?? or Java??
>>>
>
>
>>1) Place you jsp in the appropriate directory, i.e.
>><jetspeed_home>/WEB-INF/templates/jsp/portlets/<media_type>[/language]
>>
>
>>2) Add the registry entry to local-portlet.xreg.  See the registry entry
>>for HelloJSP in demo-portlets.xreg as an example. No class name is needed.
>>
>
>
>





--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>