You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by daniel robinson <dr...@dnai.com> on 2002/06/29 19:35:23 UTC
Re: XML and XSLT with Turbine
Thanks for the input. As I've said, I already have the site running
under XML/XSL. I spent a lot of time with cocoon and I'm not sure that
Turbine will work for me either. I want to introduce as few changes as
possible, re-doing the display logic in Velocity will take some time and
it is already done in XSL. Eventually what will probably happen is
that the pages will be cached as HTML and the generation will only occur
when the data changes - a fairly infrequent event. At any rate what I'm
looking for is a more concrete how-to for this.
Dan
Warner Onstine wrote:
>----- Original Message -----
>From: "daniel robinson" <dr...@dnai.com>
>To: "Turbine Users List" <tu...@jakarta.apache.org>
>Sent: Friday, June 28, 2002 11:17 PM
>Subject: XML and XSLT with Turbing
>
>
>>I currently have a web site in cocoon that queries a db to produce XML
>>data and then uses XSLT to produce HTML. I am trying to figure out how
>>to convert this to a Turbine app. I have got the TDK running with a
>>sample app and have read through all the documentation I could find and
>>searched through the mail archives. Of course I've come across the XSL
>>classes. I'm still unsure of how to use them.
>>
>>I'm sure I could struggle through this but I'm hoping that someone could
>>quickly explain the steps I need to take to:
>>
>>1) Fetch data from the database - (This seems pretty straight forward)
>>
>
>Depending on how you do it, you could use Torque Object Model, to model the
>data
>you want to pull out what you want and place it into nice container objects.
>
>>2) Wrap the data in XML tags
>>
>
>XML is nice, but what's the business need. Do you need to send xml data to
>someone else?
>If not then I would recommend using Torque to pull your data into objects,
>and a request-tool to allow you to 'pull' your data into a velocity
>template.
>
>>3) Transform the XML using XSLT
>>
>
>Unless there's a business need for XML, I would stay away from the
>performance hit.
>
>>4) Output the HTML
>>
>>Help appreciated,
>>
>>Dan
>>
>>
>>--
>>To unsubscribe, e-mail:
>>
><ma...@jakarta.apache.org>
>
>>For additional commands, e-mail:
>>
><ma...@jakarta.apache.org>
>
>>
>
>
>--
>To unsubscribe, e-mail: <ma...@jakarta.apache.org>
>For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>
>
Re: XML and XSLT with Turbine
Posted by daniel robinson <dr...@dnai.com>.
Warner,
Good idea. Once I figure it out I will write it up. I have some other
errata to contribute as well. Hopefully I'll get to it this week.
Dan
Warner Onstine wrote:
>Unfortunately I don't know anyone who is using this service and I haven't
>used it.
>
>Let us know how it goes and write up an xdoc and contribute back? Sorry, but
>the more docs we have the better we'll all be off.
>
>-warner
>
>----- Original Message -----
>From: "daniel robinson" <dr...@dnai.com>
>To: "Turbine Users List" <tu...@jakarta.apache.org>
>Sent: Monday, July 01, 2002 10:16 AM
>Subject: Re: XML and XSLT with Turbine
>
>
>>Leon,
>>
>>Yeah. I'm a complete NOOB. I found the xslt-service and was looking
>>for a no-brainer (for some obvious reasons :) ) example of it in use. I
>>read through the doco and have the demo running, I was just looking for
>>some hand-holding (oh hell, let's be frank, I don't want someone to hold
>>my hand - I want someone to CARRY me :) ). So I could get this going
>>
>ASAP.
>
>>Dan
>>
>>Leon Messerschmidt wrote:
>>
>>>Hi Dan,
>>>
>>>You can use XML in your Velocity templates and then transform it
>>>before it goes to the browser. Just setup your XSLT service:
>>>
>>>http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
>>>
>>>and use VelocityXSLTLayout
>>>
>>>~ Leon
>>>
>>>Warner Onstine wrote:
>>>
>>>>I haven't used the XSL service, but you should be able to drop in your
>>>>stylesheets as they exist already.
>>>>Here is the configuration:
>>>>http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
>>>>
>>>>and here is where I found the class referenced at the bottom of the
>>>>above
>>>>doc:
>>>>http://cvs.apache.org/viewcvs.cgi/jakarta-turbine-3/misc/
>>>>
>>>>-warner
>>>>
>>>>----- Original Message -----
>>>>From: "daniel robinson" <dr...@dnai.com>
>>>>To: "Turbine Users List" <tu...@jakarta.apache.org>
>>>>Sent: Saturday, June 29, 2002 10:35 AM
>>>>Subject: Re: XML and XSLT with Turbine
>>>>
>>>>
>>>>
>>>>>Thanks for the input. As I've said, I already have the site running
>>>>>under XML/XSL. I spent a lot of time with cocoon and I'm not sure
>>>>>
>that
>
>>>>>Turbine will work for me either. I want to introduce as few changes
>>>>>
>as
>
>>>>>possible, re-doing the display logic in Velocity will take some time
>>>>>and
>>>>>it is already done in XSL. Eventually what will probably happen is
>>>>>that the pages will be cached as HTML and the generation will only
>>>>>occur
>>>>>when the data changes - a fairly infrequent event. At any rate what
>>>>>I'm
>>>>>looking for is a more concrete how-to for this.
>>>>>
>>>>>Dan
>>>>>
>>>>>Warner Onstine wrote:
>>>>>
>>>>>
>>>>>>----- Original Message -----
>>>>>>From: "daniel robinson" <dr...@dnai.com>
>>>>>>To: "Turbine Users List" <tu...@jakarta.apache.org>
>>>>>>Sent: Friday, June 28, 2002 11:17 PM
>>>>>>Subject: XML and XSLT with Turbing
>>>>>>
>>>>>>
>>>>>>
>>>>>>>I currently have a web site in cocoon that queries a db to produce
>>>>>>>XML
>>>>>>>data and then uses XSLT to produce HTML. I am trying to figure
>>>>>>>out how
>>>>>>>to convert this to a Turbine app. I have got the TDK running with a
>>>>>>>sample app and have read through all the documentation I could
>>>>>>>find and
>>>>>>>searched through the mail archives. Of course I've come across
>>>>>>>the XSL
>>>>>>>classes. I'm still unsure of how to use them.
>>>>>>>
>>>>>>>I'm sure I could struggle through this but I'm hoping that someone
>>>>>>>could
>>>>>>>quickly explain the steps I need to take to:
>>>>>>>
>>>>>>>1) Fetch data from the database - (This seems pretty straight
>>>>>>>forward)
>>>>>>>
>>>>>>Depending on how you do it, you could use Torque Object Model, to
>>>>>>model
>>>>>>
>>>>>
>>>>the
>>>>
>>>>>>data
>>>>>>you want to pull out what you want and place it into nice container
>>>>>>
>>>>>
>>>>objects.
>>>>
>>>>>>>2) Wrap the data in XML tags
>>>>>>>
>>>>>>XML is nice, but what's the business need. Do you need to send xml
>>>>>>data
>>>>>>
>>>>>
>>>>to
>>>>
>>>>>>someone else?
>>>>>>If not then I would recommend using Torque to pull your data into
>>>>>>
>>>>>
>>>>objects,
>>>>
>>>>>>and a request-tool to allow you to 'pull' your data into a velocity
>>>>>>template.
>>>>>>
>>>>>>
>>>>>>>3) Transform the XML using XSLT
>>>>>>>
>>>>>>Unless there's a business need for XML, I would stay away from the
>>>>>>performance hit.
>>>>>>
>>>>>>
>>>>>>>4) Output the HTML
>>>>>>>
>>>>>>>Help appreciated,
>>>>>>>
>>>>>>>Dan
>>>>>>>
>>>>>>>
>>>>>>>--
>>>>>>>To unsubscribe, e-mail:
>>>>>>>
>>>>>><ma...@jakarta.apache.org>
>>>>>>
>>>>>>>For additional commands, e-mail:
>>>>>>>
>>>>>><ma...@jakarta.apache.org>
>>>>>>
>>>>>>
>>>>>>--
>>>>>>To unsubscribe, e-mail:
>>>>>>
>>>>>
>>>><ma...@jakarta.apache.org>
>>>>
>>>>>>For additional commands, e-mail:
>>>>>>
>>>>>
>>>><ma...@jakarta.apache.org>
>>>>
>>>>>>
>>>>
>>>>--
>>>>To unsubscribe, e-mail:
>>>><ma...@jakarta.apache.org>
>>>>For additional commands, e-mail:
>>>><ma...@jakarta.apache.org>
>>>>
>>>>
>>>
>>>
>>>
>>>
>>>--
>>>To unsubscribe, e-mail:
>>><ma...@jakarta.apache.org>
>>>For additional commands, e-mail:
>>><ma...@jakarta.apache.org>
>>>
>>>
>>>
>>
>>
>>--
>>To unsubscribe, e-mail:
>>
><ma...@jakarta.apache.org>
>
>>For additional commands, e-mail:
>>
><ma...@jakarta.apache.org>
>
>>
>
>
>--
>To unsubscribe, e-mail: <ma...@jakarta.apache.org>
>For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>
>
Re: XML and XSLT with Turbine
Posted by Warner Onstine <sw...@warneronstine.com>.
Unfortunately I don't know anyone who is using this service and I haven't
used it.
Let us know how it goes and write up an xdoc and contribute back? Sorry, but
the more docs we have the better we'll all be off.
-warner
----- Original Message -----
From: "daniel robinson" <dr...@dnai.com>
To: "Turbine Users List" <tu...@jakarta.apache.org>
Sent: Monday, July 01, 2002 10:16 AM
Subject: Re: XML and XSLT with Turbine
> Leon,
>
> Yeah. I'm a complete NOOB. I found the xslt-service and was looking
> for a no-brainer (for some obvious reasons :) ) example of it in use. I
> read through the doco and have the demo running, I was just looking for
> some hand-holding (oh hell, let's be frank, I don't want someone to hold
> my hand - I want someone to CARRY me :) ). So I could get this going
ASAP.
>
> Dan
>
> Leon Messerschmidt wrote:
>
> > Hi Dan,
> >
> > You can use XML in your Velocity templates and then transform it
> > before it goes to the browser. Just setup your XSLT service:
> >
> > http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
> >
> > and use VelocityXSLTLayout
> >
> > ~ Leon
> >
> > Warner Onstine wrote:
> >
> >> I haven't used the XSL service, but you should be able to drop in your
> >> stylesheets as they exist already.
> >> Here is the configuration:
> >> http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
> >>
> >> and here is where I found the class referenced at the bottom of the
> >> above
> >> doc:
> >> http://cvs.apache.org/viewcvs.cgi/jakarta-turbine-3/misc/
> >>
> >> -warner
> >>
> >> ----- Original Message -----
> >> From: "daniel robinson" <dr...@dnai.com>
> >> To: "Turbine Users List" <tu...@jakarta.apache.org>
> >> Sent: Saturday, June 29, 2002 10:35 AM
> >> Subject: Re: XML and XSLT with Turbine
> >>
> >>
> >>
> >>> Thanks for the input. As I've said, I already have the site running
> >>> under XML/XSL. I spent a lot of time with cocoon and I'm not sure
that
> >>> Turbine will work for me either. I want to introduce as few changes
as
> >>> possible, re-doing the display logic in Velocity will take some time
> >>> and
> >>> it is already done in XSL. Eventually what will probably happen is
> >>> that the pages will be cached as HTML and the generation will only
> >>> occur
> >>> when the data changes - a fairly infrequent event. At any rate what
> >>> I'm
> >>> looking for is a more concrete how-to for this.
> >>>
> >>> Dan
> >>>
> >>> Warner Onstine wrote:
> >>>
> >>>
> >>>> ----- Original Message -----
> >>>> From: "daniel robinson" <dr...@dnai.com>
> >>>> To: "Turbine Users List" <tu...@jakarta.apache.org>
> >>>> Sent: Friday, June 28, 2002 11:17 PM
> >>>> Subject: XML and XSLT with Turbing
> >>>>
> >>>>
> >>>>
> >>>>> I currently have a web site in cocoon that queries a db to produce
> >>>>> XML
> >>>>> data and then uses XSLT to produce HTML. I am trying to figure
> >>>>> out how
> >>>>> to convert this to a Turbine app. I have got the TDK running with a
> >>>>> sample app and have read through all the documentation I could
> >>>>> find and
> >>>>> searched through the mail archives. Of course I've come across
> >>>>> the XSL
> >>>>> classes. I'm still unsure of how to use them.
> >>>>>
> >>>>> I'm sure I could struggle through this but I'm hoping that someone
> >>>>> could
> >>>>> quickly explain the steps I need to take to:
> >>>>>
> >>>>> 1) Fetch data from the database - (This seems pretty straight
> >>>>> forward)
> >>>>>
> >>>>
> >>>> Depending on how you do it, you could use Torque Object Model, to
> >>>> model
> >>>
> >>>
> >> the
> >>
> >>>> data
> >>>> you want to pull out what you want and place it into nice container
> >>>
> >>>
> >> objects.
> >>
> >>>>> 2) Wrap the data in XML tags
> >>>>>
> >>>>
> >>>> XML is nice, but what's the business need. Do you need to send xml
> >>>> data
> >>>
> >>>
> >> to
> >>
> >>>> someone else?
> >>>> If not then I would recommend using Torque to pull your data into
> >>>
> >>>
> >> objects,
> >>
> >>>> and a request-tool to allow you to 'pull' your data into a velocity
> >>>> template.
> >>>>
> >>>>
> >>>>> 3) Transform the XML using XSLT
> >>>>>
> >>>>
> >>>> Unless there's a business need for XML, I would stay away from the
> >>>> performance hit.
> >>>>
> >>>>
> >>>>> 4) Output the HTML
> >>>>>
> >>>>> Help appreciated,
> >>>>>
> >>>>> Dan
> >>>>>
> >>>>>
> >>>>> --
> >>>>> To unsubscribe, e-mail:
> >>>>>
> >>>>
> >>>> <ma...@jakarta.apache.org>
> >>>>
> >>>>> For additional commands, e-mail:
> >>>>>
> >>>>
> >>>> <ma...@jakarta.apache.org>
> >>>>
> >>>>
> >>>> --
> >>>> To unsubscribe, e-mail:
> >>>
> >>>
> >> <ma...@jakarta.apache.org>
> >>
> >>>> For additional commands, e-mail:
> >>>
> >>>
> >> <ma...@jakarta.apache.org>
> >>
> >>>>
> >>>>
> >>>
> >>
> >>
> >> --
> >> To unsubscribe, e-mail:
> >> <ma...@jakarta.apache.org>
> >> For additional commands, e-mail:
> >> <ma...@jakarta.apache.org>
> >>
> >>
> >
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> >
> >
> >
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: PSML database
Posted by Hongbin Liu <ho...@indiana.edu>.
I guess I have figured something out.
I use jetspeed-1.3a3.
I was following instruction on
http://jakarta.apache.org/jetspeed/site/psml_db.html,
but the turbine-mysql.sql and populate-mysql.sql under
src/sql is not good enough. One can modify
these two files as needed. I consulted mysql error
messages and jetspeed.script under WEB-INF/db.
thanks anyway,
Hong
On Mon, 1 Jul 2002, Hongbin Liu wrote:
>
>
> Greetings all:
>
> I try to make Jetspeed use PSML database instead of
> the flat file.
>
> I have created tables in mysql:
> | ID_TABLE |
> | JETSPEED_ANON_PROFILE |
> | JETSPEED_GROUP_PROFILE |
> | JETSPEED_ROLE_PROFILE |
> | JETSPEED_USER_PROFILE |
> | TURBINE_GROUP |
> | TURBINE_PERMISSION |
> | TURBINE_ROLE |
> | TURBINE_ROLE_PERMISSION |
> | TURBINE_SCHEDULED_JOB |
> | TURBINE_USER |
> | TURBINE_USER_GROUP_ROLE |
>
> I populated the tables using populate-mysql.sql (
> this script populate TURBINE_* but not JETSPEED_* ?),
> modified TurbineResource.Properties and Torque.properties
> to reflect mysql database settings, modified Jetspeed.properties
> to use DatabasePsmlManager.
>
> When I directed the browser to :8080/jetspeed, I got errors:
>
> Horrible Exception:
> org.apache.turbine.util.security.UnknownEntityException: Unknown user
> 'anon'
> at
> org.apache.turbine.services.security.db.DBUserManager.retrieve(DBUserManager.java:178)
> at
> org.apache.turbine.services.security.BaseSecurityService.getUser(BaseSecurityService.java:329)
> at
> org.apache.jetspeed.services.security.JetspeedDBSecurityService.getAnonymousUser(JetspeedDBSecurityService.java:456)
> at
> org.apache.turbine.services.security.TurbineSecurity.getAnonymousUser(TurbineSecurity.java:246)
> at
> org.apache.turbine.modules.actions.sessionvalidator.TemplateSessionValidator.doPerform(TemplateSessionValidator.java:95)
> at
> org.apache.jetspeed.modules.actions.JetspeedSessionValidator.doPerform(JetspeedSessionValidator.java:104)
> at org.apache.turbine.modules.Action.perform(Action.java:87)
>
> ...
>
> jetspeed.log has the following:
>
> [20:04:01,436 DEBUG] SELECT TURBINE_USER.USER_ID, TURBINE_USER.LOGIN_NAME,
> TURBINE_USER.PASSWORD_VALUE, TURBINE_USER.FIRST_NAME,
> TURBINE_USER.LAST_NAME, TURBINE_USER.EMAIL, TURBINE_USER.CONFIRM_VALUE,
> TURBINE_USER.MODIFIED, TURBINE_USER.CREATED, TURBINE_USER.LAST_LOGIN,
> TURBINE_USER.DISABLED, TURBINE_USER.OBJECTDATA FROM TURBINE_USER WHERE
> (TURBINE_USER.LOGIN_NAME='anon')
> [20:04:01,442 ERROR] Turbine.handleException: Unknown user 'anon'
>
>
> Could you please inform me what's wrong with it? populate-mysql.sql
> doesn't insert a Turbine user 'anon'; so should I manually insert this
> user 'anon' to TURBINE_USER? Besides, what is 'anon' about? I thank
> in advance for your help.
>
>
> regards,
>
> hong
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>
>
****************************
Hongbin Liu
Campus View #111
Bloomington, IN 47408
Tel: (812)857-4837
Email: holiu@indiana.edu
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
PSML database
Posted by Hongbin Liu <ho...@indiana.edu>.
Greetings all:
I try to make Jetspeed use PSML database instead of
the flat file.
I have created tables in mysql:
| ID_TABLE |
| JETSPEED_ANON_PROFILE |
| JETSPEED_GROUP_PROFILE |
| JETSPEED_ROLE_PROFILE |
| JETSPEED_USER_PROFILE |
| TURBINE_GROUP |
| TURBINE_PERMISSION |
| TURBINE_ROLE |
| TURBINE_ROLE_PERMISSION |
| TURBINE_SCHEDULED_JOB |
| TURBINE_USER |
| TURBINE_USER_GROUP_ROLE |
I populated the tables using populate-mysql.sql (
this script populate TURBINE_* but not JETSPEED_* ?),
modified TurbineResource.Properties and Torque.properties
to reflect mysql database settings, modified Jetspeed.properties
to use DatabasePsmlManager.
When I directed the browser to :8080/jetspeed, I got errors:
Horrible Exception:
org.apache.turbine.util.security.UnknownEntityException: Unknown user
'anon'
at
org.apache.turbine.services.security.db.DBUserManager.retrieve(DBUserManager.java:178)
at
org.apache.turbine.services.security.BaseSecurityService.getUser(BaseSecurityService.java:329)
at
org.apache.jetspeed.services.security.JetspeedDBSecurityService.getAnonymousUser(JetspeedDBSecurityService.java:456)
at
org.apache.turbine.services.security.TurbineSecurity.getAnonymousUser(TurbineSecurity.java:246)
at
org.apache.turbine.modules.actions.sessionvalidator.TemplateSessionValidator.doPerform(TemplateSessionValidator.java:95)
at
org.apache.jetspeed.modules.actions.JetspeedSessionValidator.doPerform(JetspeedSessionValidator.java:104)
at org.apache.turbine.modules.Action.perform(Action.java:87)
...
jetspeed.log has the following:
[20:04:01,436 DEBUG] SELECT TURBINE_USER.USER_ID, TURBINE_USER.LOGIN_NAME,
TURBINE_USER.PASSWORD_VALUE, TURBINE_USER.FIRST_NAME,
TURBINE_USER.LAST_NAME, TURBINE_USER.EMAIL, TURBINE_USER.CONFIRM_VALUE,
TURBINE_USER.MODIFIED, TURBINE_USER.CREATED, TURBINE_USER.LAST_LOGIN,
TURBINE_USER.DISABLED, TURBINE_USER.OBJECTDATA FROM TURBINE_USER WHERE
(TURBINE_USER.LOGIN_NAME='anon')
[20:04:01,442 ERROR] Turbine.handleException: Unknown user 'anon'
Could you please inform me what's wrong with it? populate-mysql.sql
doesn't insert a Turbine user 'anon'; so should I manually insert this
user 'anon' to TURBINE_USER? Besides, what is 'anon' about? I thank
in advance for your help.
regards,
hong
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: XML and XSLT with Turbine
Posted by daniel robinson <dr...@dnai.com>.
Leon,
Yeah. I'm a complete NOOB. I found the xslt-service and was looking
for a no-brainer (for some obvious reasons :) ) example of it in use. I
read through the doco and have the demo running, I was just looking for
some hand-holding (oh hell, let's be frank, I don't want someone to hold
my hand - I want someone to CARRY me :) ). So I could get this going ASAP.
Dan
Leon Messerschmidt wrote:
> Hi Dan,
>
> You can use XML in your Velocity templates and then transform it
> before it goes to the browser. Just setup your XSLT service:
>
> http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
>
> and use VelocityXSLTLayout
>
> ~ Leon
>
> Warner Onstine wrote:
>
>> I haven't used the XSL service, but you should be able to drop in your
>> stylesheets as they exist already.
>> Here is the configuration:
>> http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
>>
>> and here is where I found the class referenced at the bottom of the
>> above
>> doc:
>> http://cvs.apache.org/viewcvs.cgi/jakarta-turbine-3/misc/
>>
>> -warner
>>
>> ----- Original Message -----
>> From: "daniel robinson" <dr...@dnai.com>
>> To: "Turbine Users List" <tu...@jakarta.apache.org>
>> Sent: Saturday, June 29, 2002 10:35 AM
>> Subject: Re: XML and XSLT with Turbine
>>
>>
>>
>>> Thanks for the input. As I've said, I already have the site running
>>> under XML/XSL. I spent a lot of time with cocoon and I'm not sure that
>>> Turbine will work for me either. I want to introduce as few changes as
>>> possible, re-doing the display logic in Velocity will take some time
>>> and
>>> it is already done in XSL. Eventually what will probably happen is
>>> that the pages will be cached as HTML and the generation will only
>>> occur
>>> when the data changes - a fairly infrequent event. At any rate what
>>> I'm
>>> looking for is a more concrete how-to for this.
>>>
>>> Dan
>>>
>>> Warner Onstine wrote:
>>>
>>>
>>>> ----- Original Message -----
>>>> From: "daniel robinson" <dr...@dnai.com>
>>>> To: "Turbine Users List" <tu...@jakarta.apache.org>
>>>> Sent: Friday, June 28, 2002 11:17 PM
>>>> Subject: XML and XSLT with Turbing
>>>>
>>>>
>>>>
>>>>> I currently have a web site in cocoon that queries a db to produce
>>>>> XML
>>>>> data and then uses XSLT to produce HTML. I am trying to figure
>>>>> out how
>>>>> to convert this to a Turbine app. I have got the TDK running with a
>>>>> sample app and have read through all the documentation I could
>>>>> find and
>>>>> searched through the mail archives. Of course I've come across
>>>>> the XSL
>>>>> classes. I'm still unsure of how to use them.
>>>>>
>>>>> I'm sure I could struggle through this but I'm hoping that someone
>>>>> could
>>>>> quickly explain the steps I need to take to:
>>>>>
>>>>> 1) Fetch data from the database - (This seems pretty straight
>>>>> forward)
>>>>>
>>>>
>>>> Depending on how you do it, you could use Torque Object Model, to
>>>> model
>>>
>>>
>> the
>>
>>>> data
>>>> you want to pull out what you want and place it into nice container
>>>
>>>
>> objects.
>>
>>>>> 2) Wrap the data in XML tags
>>>>>
>>>>
>>>> XML is nice, but what's the business need. Do you need to send xml
>>>> data
>>>
>>>
>> to
>>
>>>> someone else?
>>>> If not then I would recommend using Torque to pull your data into
>>>
>>>
>> objects,
>>
>>>> and a request-tool to allow you to 'pull' your data into a velocity
>>>> template.
>>>>
>>>>
>>>>> 3) Transform the XML using XSLT
>>>>>
>>>>
>>>> Unless there's a business need for XML, I would stay away from the
>>>> performance hit.
>>>>
>>>>
>>>>> 4) Output the HTML
>>>>>
>>>>> Help appreciated,
>>>>>
>>>>> Dan
>>>>>
>>>>>
>>>>> --
>>>>> To unsubscribe, e-mail:
>>>>>
>>>>
>>>> <ma...@jakarta.apache.org>
>>>>
>>>>> For additional commands, e-mail:
>>>>>
>>>>
>>>> <ma...@jakarta.apache.org>
>>>>
>>>>
>>>> --
>>>> To unsubscribe, e-mail:
>>>
>>>
>> <ma...@jakarta.apache.org>
>>
>>>> For additional commands, e-mail:
>>>
>>>
>> <ma...@jakarta.apache.org>
>>
>>>>
>>>>
>>>
>>
>>
>> --
>> To unsubscribe, e-mail:
>> <ma...@jakarta.apache.org>
>> For additional commands, e-mail:
>> <ma...@jakarta.apache.org>
>>
>>
>
>
>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: XML and XSLT with Turbine
Posted by Leon Messerschmidt <le...@opticode.co.za>.
Hi Dan,
You can use XML in your Velocity templates and then transform it before
it goes to the browser. Just setup your XSLT service:
http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
and use VelocityXSLTLayout
~ Leon
Warner Onstine wrote:
> I haven't used the XSL service, but you should be able to drop in your
> stylesheets as they exist already.
> Here is the configuration:
> http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
>
> and here is where I found the class referenced at the bottom of the above
> doc:
> http://cvs.apache.org/viewcvs.cgi/jakarta-turbine-3/misc/
>
> -warner
>
> ----- Original Message -----
> From: "daniel robinson" <dr...@dnai.com>
> To: "Turbine Users List" <tu...@jakarta.apache.org>
> Sent: Saturday, June 29, 2002 10:35 AM
> Subject: Re: XML and XSLT with Turbine
>
>
>
>>Thanks for the input. As I've said, I already have the site running
>>under XML/XSL. I spent a lot of time with cocoon and I'm not sure that
>>Turbine will work for me either. I want to introduce as few changes as
>>possible, re-doing the display logic in Velocity will take some time and
>>it is already done in XSL. Eventually what will probably happen is
>>that the pages will be cached as HTML and the generation will only occur
>>when the data changes - a fairly infrequent event. At any rate what I'm
>>looking for is a more concrete how-to for this.
>>
>>Dan
>>
>>Warner Onstine wrote:
>>
>>
>>>----- Original Message -----
>>>From: "daniel robinson" <dr...@dnai.com>
>>>To: "Turbine Users List" <tu...@jakarta.apache.org>
>>>Sent: Friday, June 28, 2002 11:17 PM
>>>Subject: XML and XSLT with Turbing
>>>
>>>
>>>
>>>>I currently have a web site in cocoon that queries a db to produce XML
>>>>data and then uses XSLT to produce HTML. I am trying to figure out how
>>>>to convert this to a Turbine app. I have got the TDK running with a
>>>>sample app and have read through all the documentation I could find and
>>>>searched through the mail archives. Of course I've come across the XSL
>>>>classes. I'm still unsure of how to use them.
>>>>
>>>>I'm sure I could struggle through this but I'm hoping that someone could
>>>>quickly explain the steps I need to take to:
>>>>
>>>>1) Fetch data from the database - (This seems pretty straight forward)
>>>>
>>>
>>>Depending on how you do it, you could use Torque Object Model, to model
>>
> the
>
>>>data
>>>you want to pull out what you want and place it into nice container
>>
> objects.
>
>>>>2) Wrap the data in XML tags
>>>>
>>>
>>>XML is nice, but what's the business need. Do you need to send xml data
>>
> to
>
>>>someone else?
>>>If not then I would recommend using Torque to pull your data into
>>
> objects,
>
>>>and a request-tool to allow you to 'pull' your data into a velocity
>>>template.
>>>
>>>
>>>>3) Transform the XML using XSLT
>>>>
>>>
>>>Unless there's a business need for XML, I would stay away from the
>>>performance hit.
>>>
>>>
>>>>4) Output the HTML
>>>>
>>>>Help appreciated,
>>>>
>>>>Dan
>>>>
>>>>
>>>>--
>>>>To unsubscribe, e-mail:
>>>>
>>>
>>><ma...@jakarta.apache.org>
>>>
>>>>For additional commands, e-mail:
>>>>
>>>
>>><ma...@jakarta.apache.org>
>>>
>>>
>>>--
>>>To unsubscribe, e-mail:
>>
> <ma...@jakarta.apache.org>
>
>>>For additional commands, e-mail:
>>
> <ma...@jakarta.apache.org>
>
>>>
>>>
>>
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: XML and XSLT with Turbine
Posted by Warner Onstine <sw...@warneronstine.com>.
I haven't used the XSL service, but you should be able to drop in your
stylesheets as they exist already.
Here is the configuration:
http://jakarta.apache.org/turbine/fulcrum/howto/xslt-service.html
and here is where I found the class referenced at the bottom of the above
doc:
http://cvs.apache.org/viewcvs.cgi/jakarta-turbine-3/misc/
-warner
----- Original Message -----
From: "daniel robinson" <dr...@dnai.com>
To: "Turbine Users List" <tu...@jakarta.apache.org>
Sent: Saturday, June 29, 2002 10:35 AM
Subject: Re: XML and XSLT with Turbine
> Thanks for the input. As I've said, I already have the site running
> under XML/XSL. I spent a lot of time with cocoon and I'm not sure that
> Turbine will work for me either. I want to introduce as few changes as
> possible, re-doing the display logic in Velocity will take some time and
> it is already done in XSL. Eventually what will probably happen is
> that the pages will be cached as HTML and the generation will only occur
> when the data changes - a fairly infrequent event. At any rate what I'm
> looking for is a more concrete how-to for this.
>
> Dan
>
> Warner Onstine wrote:
>
> >----- Original Message -----
> >From: "daniel robinson" <dr...@dnai.com>
> >To: "Turbine Users List" <tu...@jakarta.apache.org>
> >Sent: Friday, June 28, 2002 11:17 PM
> >Subject: XML and XSLT with Turbing
> >
> >
> >>I currently have a web site in cocoon that queries a db to produce XML
> >>data and then uses XSLT to produce HTML. I am trying to figure out how
> >>to convert this to a Turbine app. I have got the TDK running with a
> >>sample app and have read through all the documentation I could find and
> >>searched through the mail archives. Of course I've come across the XSL
> >>classes. I'm still unsure of how to use them.
> >>
> >>I'm sure I could struggle through this but I'm hoping that someone could
> >>quickly explain the steps I need to take to:
> >>
> >>1) Fetch data from the database - (This seems pretty straight forward)
> >>
> >
> >Depending on how you do it, you could use Torque Object Model, to model
the
> >data
> >you want to pull out what you want and place it into nice container
objects.
> >
> >>2) Wrap the data in XML tags
> >>
> >
> >XML is nice, but what's the business need. Do you need to send xml data
to
> >someone else?
> >If not then I would recommend using Torque to pull your data into
objects,
> >and a request-tool to allow you to 'pull' your data into a velocity
> >template.
> >
> >>3) Transform the XML using XSLT
> >>
> >
> >Unless there's a business need for XML, I would stay away from the
> >performance hit.
> >
> >>4) Output the HTML
> >>
> >>Help appreciated,
> >>
> >>Dan
> >>
> >>
> >>--
> >>To unsubscribe, e-mail:
> >>
> ><ma...@jakarta.apache.org>
> >
> >>For additional commands, e-mail:
> >>
> ><ma...@jakarta.apache.org>
> >
> >>
> >
> >
> >--
> >To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> >For additional commands, e-mail:
<ma...@jakarta.apache.org>
> >
> >
> >
>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>