[opencms-dev] RE:Again on JSP with template

Domenico De Seta domenico.deseta at tiscali.it
Sun May 23 19:16:01 CEST 2004


Hi Jose, (sorry I called you Garcia in a previous e-mail),

thank you so much, your explanation was really detailed and clear!
Actually I was missing the last point in the process, i.e. to insert the
appropriate cms:include tags in the .jsp file to which I want to apply
my template. That's fine, now it works, thanks to you!

Cheers

Domenico



-----Messaggio originale-----
Da: opencms-dev-admin at opencms.org [mailto:opencms-dev-admin at opencms.org]
Per conto di opencms-dev-request at opencms.org
Inviato: domenica 23 maggio 2004 9.48
A: opencms-dev at opencms.org
Oggetto: opencms-dev digest, Vol 1 #1149 - 3 msgs

Send opencms-dev mailing list submissions to
	opencms-dev at opencms.org

To subscribe or unsubscribe via the World Wide Web, visit
	http://mail.opencms.org/mailman/listinfo/opencms-dev
or, via email, send a message with subject or body 'help' to
	opencms-dev-request at opencms.org

You can reach the person managing the list at
	opencms-dev-admin at opencms.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of opencms-dev digest..."


Today's Topics:

   1. RE: To the developers team (Cory Hubert)
   2. Again on JSP with template (Domenico De Seta)
   3. RE: Again on JSP with template
(=?iso-8859-1?Q?Jos=E9_Checa_Claudel?=)

--__--__--

Message: 1
From: "Cory Hubert" <cory.hubert at ampagency.com>
To: <opencms-dev at opencms.org>
Subject: RE: [opencms-dev] To the developers team
Date: Sat, 22 May 2004 12:18:10 -0400
Reply-To: opencms-dev at opencms.org



> Now is the only problem i see there the point How to create new
classes on
> the fly when new modules were installed. For this, we must implement
an
>  "On-The-Fly" Way to create the mapping classes and save them to the
right
> places. After this we must compile them (this can be done via ANT or
> BeanShell i think)

	AHHH.  I had to deal with this pattern before.   I think our
best bet is to
avoid class creation on the fly.  Just generate the SQL and use
something
like QueryBySQL in the OR Mapping layer.  OR Mapping is only really
effective if you know your target tables before developing.  I guess the
same holds true for straight JDBC/SQL.  I've created tables on the fly
and
in the same user session do CRUD operations against those tables, but
it's a
lot of work.  It looks cool when your done though :)

	Which brings me to the ultimate question.  Why do we need to do
this?   If
we are installing a new module that creates tables and we can just add
the
descriptors for those OR mapped classes dynamically?  Create the table,
drop
the classes in the VFS, and dynamically add the class/table descriptor
through the OR mapping api.   We can add it to the main descriptor file
so
when you restart the webapp the table(s)/class relationship is still
there.

	For backward compatibility.  If it doesn't have any OR mapping
in it.  Just
use the OR mapping API as a proxy for the Connection Pool and Db
Connection
setting and execute the straight SQL through it.


--__--__--

Message: 2
From: "Domenico De Seta" <domenico.deseta at tiscali.it>
To: "Opencms-Dev" <opencms-dev at opencms.org>
Date: Sun, 23 May 2004 00:00:52 +0200
Subject: [opencms-dev] Again on JSP with template
Reply-To: opencms-dev at opencms.org

This is a multi-part message in MIME format.

------=_NextPart_000_0001_01C44059.03CE3850
Content-Type: text/plain;
	charset="Windows-1252"
Content-Transfer-Encoding: 7bit

 
 
Hi Arian (is this your name?),
 
Thank you for the answer but I am not quite sure to understand how to
use it: could you please clarify where the piece of code you suggest
must be put? Which element must be substituted with specific data, I
guess "yourjsp.jsp" refers to my JSP page (correct?), but what about
<template><element name="jsp"/></template> ?
 
Regards
 
Domenico=20
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.687 / Virus Database: 448 - Release Date: 16/05/2004
 

------=_NextPart_000_0001_01C44059.03CE3850
Content-Type: text/html;
	charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

<html xmlns:o=3D"urn:schemas-microsoft-com:office:office" =
xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns:st1=3D"urn:schemas-microsoft-com:office:smarttags" =
xmlns=3D"http://www.w3.org/TR/REC-html40">

<head>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3DWindows-1252">


<meta name=3DProgId content=3DWord.Document>
<meta name=3DGenerator content=3D"Microsoft Word 10">
<meta name=3DOriginator content=3D"Microsoft Word 10">
<link rel=3DFile-List href=3D"cid:filelist.xml at 01C44059.02F23030">
<o:SmartTagType =
namespaceuri=3D"urn:schemas-microsoft-com:office:smarttags"
 name=3D"PersonName"/>
<!--[if gte mso 9]><xml>
 <o:OfficeDocumentSettings>
  <o:DoNotRelyOnCSS/>
 </o:OfficeDocumentSettings>
</xml><![endif]--><!--[if gte mso 9]><xml>
 <w:WordDocument>
  <w:SpellingState>Clean</w:SpellingState>
  <w:GrammarState>Clean</w:GrammarState>
  <w:DocumentKind>DocumentEmail</w:DocumentKind>
  <w:HyphenationZone>14</w:HyphenationZone>
  <w:EnvelopeVis/>
  <w:Compatibility>
   <w:BreakWrappedTables/>
   <w:SnapToGridInCell/>
   <w:WrapTextWithPunct/>
   <w:UseAsianBreakRules/>
   <w:UseFELayout/>
  </w:Compatibility>
  <w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
 </w:WordDocument>
</xml><![endif]--><!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
 /* Font Definitions */
 @font-face
	{font-family:SimSun;
	panose-1:2 1 6 0 3 1 1 1 1 1;
	mso-font-alt:\5B8B\4F53;
	mso-font-charset:134;
	mso-generic-font-family:auto;
	mso-font-pitch:variable;
	mso-font-signature:3 135135232 16 0 262145 0;}
@font-face
	{font-family:"\@SimSun";
	panose-1:2 1 6 0 3 1 1 1 1 1;
	mso-font-charset:134;
	mso-generic-font-family:auto;
	mso-font-pitch:variable;
	mso-font-signature:3 135135232 16 0 262145 0;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{mso-style-update:auto;
	mso-style-parent:"";
	margin:0cm;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:11.0pt;
	mso-bidi-font-size:12.0pt;
	font-family:Arial;
	mso-fareast-font-family:SimSun;
	mso-bidi-font-family:"Times New Roman";}
a:link, span.MsoHyperlink
	{color:blue;
	text-decoration:underline;
	text-underline:single;}
a:visited, span.MsoHyperlinkFollowed
	{color:purple;
	text-decoration:underline;
	text-underline:single;}
p.MsoAutoSig, li.MsoAutoSig, div.MsoAutoSig
	{margin:0cm;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:12.0pt;
	font-family:"Times New Roman";
	mso-fareast-font-family:"Times New Roman";
	mso-fareast-language:IT;}
span.StileMessaggioDiPostaElettronica17
	{mso-style-type:personal-compose;
	mso-style-noshow:yes;
	mso-ansi-font-size:10.0pt;
	mso-bidi-font-size:10.0pt;
	font-family:Arial;
	mso-ascii-font-family:Arial;
	mso-hansi-font-family:Arial;
	mso-bidi-font-family:Arial;
	color:windowtext;}
span.SpellE
	{mso-style-name:"";
	mso-spl-e:yes;}
@page Section1
	{size:595.3pt 841.9pt;
	margin:70.85pt 2.0cm 2.0cm 2.0cm;
	mso-header-margin:35.4pt;
	mso-footer-margin:35.4pt;
	mso-paper-source:0;}
div.Section1
	{page:Section1;}
-->
</style>
<!--[if gte mso 10]>
<style>
 /* Style Definitions */=20
 table.MsoNormalTable
	{mso-style-name:"Tabella normale";
	mso-tstyle-rowband-size:0;
	mso-tstyle-colband-size:0;
	mso-style-noshow:yes;
	mso-style-parent:"";
	mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
	mso-para-margin:0cm;
	mso-para-margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:10.0pt;
	font-family:"Times New Roman";}
</style>
<![endif]-->
</head>

<body lang=3DIT link=3Dblue vlink=3Dpurple =
style=3D'tab-interval:35.4pt'>

<div class=3DSection1>

<p class=3DMsoNormal><font size=3D2 =
face=3DArial><o:p> </o:p></font></p>

<p class=3DMsoNormal><font size=3D2 =
face=3DArial><o:p> </o:p></font></p>

<p class=3DMsoNormal =
style=3D'mso-layout-grid-align:none;text-autospace:none'><font
size=3D2 face=3D"Courier New"><span lang=3DEN-GB =
style=3D'font-size:10.0pt;font-family:
"Courier New";mso-ansi-language:EN-GB'>Hi Arian (is this your =
name?),<o:p></o:p></span></font></p>

<p class=3DMsoNormal =
style=3D'mso-layout-grid-align:none;text-autospace:none'><font
size=3D2 face=3D"Courier New"><span lang=3DEN-GB =
style=3D'font-size:10.0pt;font-family:
"Courier =
New";mso-ansi-language:EN-GB'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal =
style=3D'mso-layout-grid-align:none;text-autospace:none'><font
size=3D2 face=3D"Courier New"><span lang=3DEN-GB =
style=3D'font-size:10.0pt;font-family:
"Courier New";mso-ansi-language:EN-GB'>Thank you for the answer but I am
=
not
quite sure to understand how to use it: could you please clarify where =
the
piece of code you suggest must be put? Which element must be substituted
=
with
specific data, I guess "<span =
class=3DSpellE>yourjsp.jsp</span>" refers
to my JSP page (correct?), but what about <template><element =
name=3D"jsp"/></template>
?<o:p></o:p></span></font></p>

<p class=3DMsoNormal =
style=3D'mso-layout-grid-align:none;text-autospace:none'><font
size=3D2 face=3D"Courier New"><span lang=3DEN-GB =
style=3D'font-size:10.0pt;font-family:
"Courier =
New";mso-ansi-language:EN-GB'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal =
style=3D'mso-layout-grid-align:none;text-autospace:none'><span
class=3DSpellE><font size=3D2 face=3D"Courier New"><span =
style=3D'font-size:10.0pt;
font-family:"Courier New"'>Regards</span></font></span><font size=3D2
face=3D"Courier New"><span =
style=3D'font-size:10.0pt;font-family:"Courier =
New"'><o:p></o:p></span></font></p>

<p class=3DMsoNormal =
style=3D'mso-layout-grid-align:none;text-autospace:none'><font
size=3D2 face=3D"Courier New"><span =
style=3D'font-size:10.0pt;font-family:"Courier =
New"'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal =
style=3D'mso-layout-grid-align:none;text-autospace:none'><st1:PersonName
>=
<font
 size=3D2 face=3D"Courier New"><span =
style=3D'font-size:10.0pt;font-family:"Courier =
New"'>Dom</span></font></st1:PersonName><font
size=3D2 face=3D"Courier New"><span =
style=3D'font-size:10.0pt;font-family:"Courier =
New"'>enico=3D20<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 =
face=3DArial><o:p> </o:p></font></p>

</div>

</body>

</html>
<BR>

<P><FONT SIZE=3D2>---<BR>
Outgoing mail is certified Virus Free.<BR>
Checked by AVG anti-virus system (http://www.grisoft.com).<BR>
Version: 6.0.687 / Virus Database: 448 - Release Date: 16/05/2004<BR>
</FONT> </P>

------=_NextPart_000_0001_01C44059.03CE3850--


--__--__--

Message: 3
From: =?iso-8859-1?Q?Jos=E9_Checa_Claudel?= <jcheca at uco.es>
To: <opencms-dev at opencms.org>
Subject: RE: [opencms-dev] Again on JSP with template
Date: Sun, 23 May 2004 10:47:52 +0200
Organization: =?iso-8859-1?Q?Universidad_de_C=F3rdoba?=
Reply-To: opencms-dev at opencms.org

This is a multi-part message in MIME format.

------=_NextPart_000_000C_01C440B3.664C3310
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi Domenico, I=92ve been reading your posts and I think you are a bit
confused. I=92ll try to explain you in a few words.

=20

1=BA) You will have to do your template: these are two files (2), a =
definition
file within an XML and a .JSP file to define the squeletom of your page
(your real  template). In your /system/modules/<yourmodule>/template =
will
define this two files:

=20

File1 =96 definition:=20

=20

<?xml version=3D"1.0" encoding=3D"ISO-8859-1"?>

<xmltemplate>

=20

   <stylesheet></stylesheet>

=20

   <template>

      <element name=3D"def01"/>

   </template>

=20

   <elementdef name=3D"def01">

      <class>com.opencms.flex.CmsJspTemplate</class>  =20

      <template>esqueletom.jsp</template>

   </elementdef>

   =20

</xmltemplate>

=20

File2- esqueletom.jsp:

=20

<%@ page session=3D"false" %>

<%@ taglib prefix=3D"cms" uri=3D"http://www.opencms.org/taglib/cms" %>

=20

<html>

<title>Header File</title>

<body>

=20

  <cms:include element=3D"body" />  =20

=20

</body>

</html>

=20

That=92s all; from now you could create a new .html file, select this
template, and all information you write in your editor, would be embebed
instead of <cms:include element=3D"body" />. =BF ok ? .... simple =
template
functions !!

=20

But, what=92s happend with new .JSP files, there are no posibilities to
=
select
any template, so ...

=20

When you create a .JSP file, you will have to do some steps to use the
template:

=20

1=BA) you will have to create a new property for this new .jsp file, the
=
name
of this property is =91template=92 and the value would be the name of =
the
esqueletom.jsp file with all path
(/system/modules/<yourmodule>/esqueletom.jsp). This way, we select the
template for .JSP !! don=92t forget it !!

=20

2=BA) in your esqueletom.jsp will have to make some changes, look:

=20

<%@ page session=3D"false" %>

<%@ taglib prefix=3D"cms" uri=3D"http://www.opencms.org/taglib/cms" %>

=20

<cms:template element=3D"head">

   <html>

   <title>Header File</title>

   <body>

</cms:template>

=20

<cms:include element=3D"body" />  =20

=20

<cms:template element=3D"foot">

  </body>

  </html>

</cms:template>

=20

... we use two new tag=92s, one to define =93head=94 area and other =
=93foot=94 area.

=20

3=BA) in your .JSP page, you will have to include the areas of this =
template
in your code, for instance:

=20

<%@ page session=3D"false" %>

<%@ taglib prefix=3D"cms" uri=3D"http://www.opencms.org/taglib/cms" %>

<%@ page import=3D"java.io.*" %>

=20

<cms:include property=3D"template" element=3D"head" />

   La hora actual es <%=3D new java.util.Date() %><p>

<cms:include property=3D"template" element=3D"foot" />

=20

=20

That=92s all. I hope this will be usefull, this time.

=20

Jose Checa =96 jcheca at uco.es

Universidad de C=F3rdoba - Spain

  _____ =20

De: opencms-dev-admin at opencms.org [mailto:opencms-dev-admin at opencms.org]
=
En
nombre de Domenico De Seta
Enviado el: domingo, 23 de mayo de 2004 0:01
Para: Opencms-Dev
Asunto: [opencms-dev] Again on JSP with template

=20

=20

=20

Hi Arian (is this your name?),

=20

Thank you for the answer but I am not quite sure to understand how to =
use
it: could you please clarify where the piece of code you suggest must be
put? Which element must be substituted with specific data, I guess
"yourjsp.jsp" refers to my JSP page (correct?), but what about
<template><element name=3D"jsp"/></template> ?

=20

Regards

=20

Domenico=3D20

=20


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.687 / Virus Database: 448 - Release Date: 16/05/2004



------=_NextPart_000_000C_01C440B3.664C3310
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" =
xmlns:o=3D"urn:schemas-microsoft-com:office:office" =
xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns=3D"http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<meta name=3DGenerator content=3D"Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<style>
<!--
 /* Font Definitions */
 @font-face
	{font-family:SimSun;
	panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
	{font-family:"\@SimSun";}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0cm;
	margin-bottom:.0001pt;
	font-size:10.0pt;
	font-family:Arial;}
a:link, span.MsoHyperlink
	{color:blue;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{color:purple;
	text-decoration:underline;}
p.MsoAutoSig, li.MsoAutoSig, div.MsoAutoSig
	{margin:0cm;
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Times New Roman";}
span.EstiloCorreo18
	{mso-style-type:personal;
	font-family:Arial;
	color:windowtext;}
span.EstiloCorreo20
	{mso-style-type:personal-reply;
	font-family:Arial;
	color:navy;}
@page Section1
	{size:595.3pt 841.9pt;
	margin:70.85pt 2.0cm 2.0cm 2.0cm;}
div.Section1
	{page:Section1;}
-->
</style>

</head>

<body lang=3DCA link=3Dblue vlink=3Dpurple>

<div class=3DSection1>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>Hi
Domenico, I’ve been reading your posts and I think you are a bit
confused. I’ll try to explain you in a few =
words.<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>1=BA)
You will have to do your template: these are two files (2), a definition
=
file
within an XML and a .JSP file to define the squeletom of your page (your
=
real =A0template).
In your /system/modules/<yourmodule>/template will define this two
=
files:<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>File1
– definition: <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><?xml
version=3D"1.0" =
encoding=3D"ISO-8859-1"?><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><xmltemplate><o:p></o:p></span></font><
/=
p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0
<stylesheet></stylesheet><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0
<template><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0=A0=A0=A0
<element name=3D"def01"/><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0
</template><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0
<elementdef name=3D"def01"><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0=A0=A0=A0
<class>com.opencms.flex.CmsJspTemplate</class>=A0=A0 =
<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0=A0=A0=A0
<template>esqueletom.jsp</template><o:p></o:p></span></font>
<=
/p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0
</elementdef><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0=A0 <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'></xmltemplate><o:p></o:p></span></font>
<=
/p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>File2-
esqueletom.jsp:<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><%@
page session=3D"false" %><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><%@
taglib prefix=3D"cms" =
uri=3D"http://www.opencms.org/taglib/cms"
%><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><html><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><title>Header
File</title><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><body><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0 <cms:include
element=3D"body" />=A0=A0 <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'></body><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'></html><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>That’s
all; from now you could create a new .html file, select this template, =
and all information
you write in your editor, would be embebed instead of <cms:include
element=3D"body" />. =BF ok ? .... simple template =
functions !!<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>But,
what’s happend with new .JSP files, there are no posibilities to =
select
any template, so ...<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>When
you create a .JSP file, you will have to do some steps to use the =
template:<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>1=BA)
you will have to create a new property for this new .jsp file, the name
=
of this
property is ‘template’ and the value would be the name of =
the
esqueletom.jsp file with all path =
(/system/modules/<yourmodule>/esqueletom.jsp).
This way, we select the template for .JSP !! don’t forget it =
!!<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>2=BA)
in your esqueletom.jsp will have to make some changes, =
look:<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><%@
page session=3D"false" %><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><%@
taglib prefix=3D"cms" =
uri=3D"http://www.opencms.org/taglib/cms"
%><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><cms:template
element=3D"head"><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0 =
<html><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0 <title>Header
File</title><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0 =
<body><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'></cms:template><o:p></o:p></span></font
>=
</p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><cms:include
element=3D"body" />=A0=A0 <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><cms:template
element=3D"foot"><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0 =
</body><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0 =
</html><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'></cms:template><o:p></o:p></span></font
>=
</p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>... we
use two new tag’s, one to define “head” area and other
=
“foot”
area.<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>3=BA)
in your .JSP page, you will have to include the areas of this template =
in your
code, for instance:<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><%@
page session=3D"false" %><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><%@
taglib prefix=3D"cms" =
uri=3D"http://www.opencms.org/taglib/cms"
%><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><%@
page import=3D"java.io.*" %><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><cms:include
property=3D"template" element=3D"head" =
/><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>=A0=A0 La
hora actual es <%=3D new java.util.Date() =
%><p><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><cms:include
property=3D"template" element=3D"foot" =
/><o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>That’s
all. I hope this will be usefull, this =
time.<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>Jose
Checa – <a =
href=3D"mailto:jcheca at uco.es">jcheca at uco.es</a><o:p></o:p></span></font>
<=
/p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'>Universidad
de C=F3rdoba - Spain<o:p></o:p></span></font></p>

<div>

<div class=3DMsoNormal align=3Dcenter style=3D'text-align:center'><font
=
size=3D2
face=3DArial><span lang=3DES style=3D'font-size:10.0pt'>

<hr size=3D2 width=3D"100%" align=3Dcenter tabindex=3D-1>

</span></font></div>

<p class=3DMsoNormal><b><font size=3D2 face=3DArial><span lang=3DES =
style=3D'font-size:
10.0pt;font-weight:bold'>De:</span></font></b><span lang=3DES>
opencms-dev-admin at opencms.org [mailto:opencms-dev-admin at opencms.org] =
<b><span
style=3D'font-weight:bold'>En nombre de </span></b>Domenico De Seta<br>
<b><span style=3D'font-weight:bold'>Enviado el:</span></b> domingo, 23 =
de mayo de
2004 0:01<br>
<b><span style=3D'font-weight:bold'>Para:</span></b> Opencms-Dev<br>
<b><span style=3D'font-weight:bold'>Asunto:</span></b> [opencms-dev] =
Again on JSP
with template</span><font size=3D3 face=3D"Times New Roman"><span =
lang=3DES
style=3D'font-size:12.0pt;font-family:"Times New =
Roman"'><o:p></o:p></span></font></p>

</div>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DIT =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DIT =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DEN-GB =
style=3D'font-size:
10.0pt'>Hi Arian (is this your name?),<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DEN-GB =
style=3D'font-size:
10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DEN-GB =
style=3D'font-size:
10.0pt'>Thank you for the answer but I am not quite sure to understand =
how to
use it: could you please clarify where the piece of code you suggest =
must be
put? Which element must be substituted with specific data, I guess =
"yourjsp.jsp"
refers to my JSP page (correct?), but what about =
<template><element
name=3D"jsp"/></template> =
?<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DEN-GB =
style=3D'font-size:
10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DIT =
style=3D'font-size:10.0pt'>Regards<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DIT =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DIT =
style=3D'font-size:10.0pt'>Domenico=3D20<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span lang=3DIT =
style=3D'font-size:10.0pt'><o:p> </o:p></span></font></p>

</div>

</body>

</html>
<BR>

<P><FONT SIZE=3D2>---<BR>
Outgoing mail is certified Virus Free.<BR>
Checked by AVG anti-virus system (http://www.grisoft.com).<BR>
Version: 6.0.687 / Virus Database: 448 - Release Date: 16/05/2004<BR>
</FONT> </P>
------=_NextPart_000_000C_01C440B3.664C3310--



--__--__--

_______________________________________________
This mail is send to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please
visit 
http://mail.opencms.org/mailman/listinfo/opencms-dev

End of opencms-dev Digest

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.687 / Virus Database: 448 - Release Date: 16/05/2004
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.687 / Virus Database: 448 - Release Date: 16/05/2004
 




More information about the opencms-dev mailing list