RE: can't output text before document element

2001-09-06 Thread JEULIN Olivier





 Hello World!
 
  This is my first Cocoon page!
 

 
the testsheet.xsl
 

http://www.w3.org/1999/XSL/Transform";>


you don't even create a root element with your stylesheet.
create a template matching 'page' or '/':

   
  
 
  
   


-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: get xml-file into a xsp

2001-09-06 Thread JEULIN Olivier

> but what i now need, is a xsp-function, which gets the content of an
> xml-file (because i want to select something before 
> formatting it in an
> xsl).

read the samples in your 'samples/xinclude/' distribution of cocoon (this
path is for C1, but I guess there's one for C2 too)
Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Pure XML & Javascript on client-side

2001-08-31 Thread JEULIN Olivier

>  onclick="function(getAttribute('name'))">
> 
> becomes
> 
>  onclick="function(getAttribute('name'))">

try something like this:

  function(getAttribute('name'))

or
with 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: javascript on cocoon

2001-08-24 Thread JEULIN Olivier

> I'm trying to build a website with two frames, one for 
> navigation purposes
> and a second one for the main content.
> I'm checking out JavaScript; I'm not very familiar with it, 
> but I got it
> working in XMLSpy with saxon.
> The problem is that JavaScript is often complaining about newlines
> (that I don't know where they are coming from), that it makes it very
> difficult for me working with
> it.

That's right, you have to be carefull, when you write javascript in your
stylesheet.
Pay attention to extra spaces/carriage returns/tabs when formating the XSL
in your editor.
Smart editors indent XSL well, but they also mess things up when you work
with code...
I put all my javascript code in a , and it is outputed just the
way it looks in my stylesheet (see below).

> So one question is: are there other possibilities for 
> building frames out
> of one single xml-file? 

I'm not really familiar with javascript, and I try to avoid complex things,
so my suggestions are:
1) you could use a basic HTML file to build the frameset, each frame
pointing to the appropriate HTML/XML file
2) if you really want to build the frameset from one XML file with
javascript, try to use CDATA sections like this (only the 'xsl:value-of' or
XSLT stuffs are "outside"):

   
  



   

Note: you don't have to use

 is enough.
Same thing for ,  doas the same thing and it's
shorter

> The second question concerns cocoon (1.8.2 on tomcat 3.2.1): 
> cocoon won't
> display the frames (only shows the main frame) but doesn't give an
> error message. I am missing something?

It's a browser issue; look at the HTML source of the page to see what
happens.
Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: esql logicsheet, insert, update and delete, examples

2001-08-09 Thread JEULIN Olivier

> > I'll send you an example in a few minutes (I'm not sure the 
> rest of the
> > mailing list would be interested)
> 
> I would

OK, then:
this an old file I made to test something in the xml fragment I read from
the DB, and I've changed a few things between the working version and this
one.
It's a kind of draft, so don't take it too seriously
Anyway, the queries were OK when I first tested this file, and that's what
you're looking for.

Olivier








http://www.apache.org/1999/XSP/Core";
xmlns:auth="http://ulim.cocoonhost.com/auth";
xmlns:request="http://www.apache.org/1999/XSP/Request";
xmlns:session="http://www.apache.org/1999/XSP/Session";
xmlns:foo="http://localhost/foo";
xmlns:common="http://localhost/common";
xmlns:fragmentation="http://localhost/fragmentation";
xmlns:esql="http://apache.org/cocoon/SQL/v2";
xmlns:util="http://www.apache.org/1999/XSP/Util";
xmlns:xinclude="http://www.w3.org/1999/XML/xinclude";
>

localhost.basket.Basket


 
public Basket basket;






(Boolean)
(Boolean)





if ( != null)
{   
if (
!= null 
 != null 
 != null 
 != null ) {
try {
if
(Integer.parseInt((String)) > 0) {
// nouvelle commande de ce
produit
if
( == null) {
basket = new
Basket(5);
} else {
basket =
(Basket);
}

float promo;
try {
promo =
Float.parseFloat((String));
} catch
(NumberFormatException exc) {
promo =
Float.parseFloat((String));
}
basket.addProduct(

Integer.parseInt((String)),

(String),

Integer.parseInt((String)),

Float.parseFloat((String)),
promo
);

basket;

} else {
// supprime la commande de
ce produit

}
} catch (NumberFormatException exc)
{
// ne fait rien
}
}




foo

  
select p.promotion as promo,
p.reference as ref
from newprice p
  

  
 




 
  





foo

  
select b.reference as ref,
b.quantity as nb
from basket b
where
b.user=''
and b.idtitle =
Integer.parseInt((String))
  

  
 

RE: esql logicsheet, insert, update and delete, examples

2001-08-09 Thread JEULIN Olivier

I'll send you an example in a few minutes (I'm not sure the rest of the
mailing list would be interested)

> does anybody have any examples where you insert, update and 
> delete records
> in databases, using xsp and esql logicsheet?

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Connecting database and XML pages

2001-08-08 Thread JEULIN Olivier

> I did as you said, but I still get the same error message. 

OK, I've tried to use MySQL or Mysql (in the
processor.xsp.pool.database.adaptor lines): and I got the exception too.
So try to use DBMM instead of MySQL or Mysql, and it works... Dunno why...
It seems to be a name conflict.
I hope this will work for you too!
Olivier
(here is my pool configuration just to be sure we have the same kind of
things)
--start of my pool conf--

# Turbine DB Connection Pool


# These are your database settings, look in the
# org.apache.turbine.util.db.pool.* package for more information.
processor.xsp.pool.database.foo.driver=org.gjt.mm.mysql.Driver
processor.xsp.pool.database.foo.url=jdbc:mysql://your.server/foo
processor.xsp.pool.database.foo.username=foouser
processor.xsp.pool.database.foo.password=foopwd
processor.xsp.pool.database.foo.maxConnections=5
processor.xsp.pool.database.foo.expiryTime=360

# These are the supported jdbc-drivers and their adaptors.
# These properties are used by the DBFactory.
processor.xsp.pool.database.adaptor=DBMM
#processor.xsp.pool.database.adaptor.DBWeblogic=weblogic.jdbc.pool.Driver
#processor.xsp.pool.database.adaptor.DBOracle=oracle.jdbc.driver.OracleDrive
r
#processor.xsp.pool.database.adaptor.DBInstantDB=org.enhydra.instantdb.jdbc.
idbDriver
#processor.xsp.pool.database.adaptor.DBPostgres=postgresql.Driver
#processor.xsp.pool.database.adaptor.DBInformix=com.informix.jdbc.IfxDriver
#processor.xsp.pool.database.adaptor.DBSybase=com.sybase.jdbc.SybDriver
processor.xsp.pool.database.adaptor.DBMM=org.gjt.mm.mysql.Driver

# The full path name to a pool log file
# if not given, commands to log events using org.apache.turbine.util.Log
will be ignored.
# This file must already exist and be writable.
# Default: none
processor.xsp.pool.logfile=/var/log/dbPool.log

--end of my pool conf--

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: ESQLl where condition

2001-08-08 Thread JEULIN Olivier

It should work.
The only problem I can think of, is that something goes wrong when the java
class is generated.
So take a look at it (in your 'repository' directory) and search for the
string "select deviceID, description from terminal" to see if it's correct
or not (truncated for exemple).


# original message #

I'm trying to run a query and it will not work properly. in mysql I have two
tables and I run the following query:
 
mysql> select deviceID, description from terminal, deviceType where
deviceType.deviceType = terminal.deviceType;
+--+-+
| deviceID | description |
+--+-+
| 57685251 | PSTN|
| 57685251 | PSTN|
| 22671300 | ISDN|
| 90098999 | GSM |
| 95755499 | GSM |
+--+-+
5 rows in set (0.00 sec)
 
When I try to run it on a xsp page (see code at the bottom of the page) I
get the following result:
 
Device ID Description 
90098999 PSTN 
95755499 PSTN 
57685251 PSTN 
22671300 PSTN 
57685251 PSTN 
90098999 ISDN 
95755499 ISDN 
57685251 ISDN 
22671300 ISDN 
57685251 ISDN 
90098999 GSM 
95755499 GSM 
57685251 GSM 
22671300 GSM 
57685251 GSM 


As far as I can see the where condition is not working when I run it in the
xsp page (as you can see below this is the result when the query is run
without the condition).
 
mysql> select deviceID, description from terminal, deviceType;
+--+-+
| deviceID | description |
+--+-+
| 90098999 | PSTN|
| 95755499 | PSTN|
| 57685251 | PSTN|
| 22671300 | PSTN|
| 57685251 | PSTN|
| 90098999 | ISDN|
| 95755499 | ISDN|
| 57685251 | ISDN|
| 22671300 | ISDN|
| 57685251 | ISDN|
| 90098999 | GSM |
| 95755499 | GSM |
| 57685251 | GSM |
| 22671300 | GSM |
| 57685251 | GSM |
+--+-+
15 rows in set (0.00 sec)

What's the problem? Is there something special about the esql syntax? Or is
it something else?
 
Anybody who can figure it out?
 
/Anne Marie
 
 


  select deviceID, description from terminal, deviceType where
deviceType.deviceType = terminal.deviceType;

(snip)

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Connecting database and XML pages

2001-08-08 Thread JEULIN Olivier

> I tried to implement your example, but can't get the 
> connection pooling to
> work (I guess). It _works_ when I _don't_ use pooling, so I 
> can't understand
> what's wrong. The driver is mm.mysql 2.0.4 and is located in
> TOMCAT_HOME/lib.
> 
> Below is the error message and cocoon.properties:
> 
> ---
> Error found handling the request.
> java.lang.RuntimeException: Error opening pooled connection: 
> annemarie:
> Database type org.gjt.mm.mysql.Driver not implemented.
(snip)
> 
> --
> From my cocoon.properties:
> 
> 
> # Turbine DB Connection Pool
> 
(snip)
> # These are the supported jdbc-drivers and their adaptors.
> # These properties are used by the DBFactory.
> 
> #Inserted 01-08-2001:
> processor.xsp.pool.database.adaptor=DBMM
> processor.xsp.pool.database.adaptor.DBMM=org.gjt.mm.mysql.Driver
oops, you define the driver twice ^^^

> processor.xsp.pool.database.adaptor=DBWeblogic,DBOracle,DBInst
> antDB,DBPostgr
> es,DBSybase,DBInformix,DBMySQL
> processor.xsp.pool.database.adaptor.DBWeblogic=weblogic.jdbc.p
> ool.Driver
> processor.xsp.pool.database.adaptor.DBOracle=oracle.jdbc.drive
> r.OracleDriver
> processor.xsp.pool.database.adaptor.DBInstantDB=org.enhydra.in
> stantdb.jdbc.i
> dbDriver
> processor.xsp.pool.database.adaptor.DBPostgres=postgresql.Driver
> processor.xsp.pool.database.adaptor.DBInformix=com.informix.jd
> bc.IfxDriver
> processor.xsp.pool.database.adaptor.DBSybase=com.sybase.jdbc.SybDriver
> processor.xsp.pool.database.adaptor.DBMySQL=org.gjt.mm.mysql.Driver

oops, you define the driver twice ^^^
(and the last definition is taken into account)
you must have only one definition of the driver, so
rename DBMM to DBMySQL in
processor.xsp.pool.database.adaptor=DBMM
and delete the line
processor.xsp.pool.database.adaptor.DBMM=org.gjt.mm.mysql.Driver
(I'm *very* sorry for the trouble, I've renamed DBMySQL to DBMM and
suppressed the other drivers definitions for tests , and forgot to change it
back in my configuration)
Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: [C1] ESQL in XSL

2001-08-06 Thread JEULIN Olivier

I use ESQL in one of my logicsheet (see below).
I think you have to put xmlns:esql="http://apache.org/cocoon/SQL/v2"; in your
XML file if you use ESQL in a logicsheet (I use ESQL in both the XML file
and the logicsheet, so I didn't have any troubles).

##

http://www.apache.org/1999/XSP/Core";
xmlns:esql="http://apache.org/cocoon/SQL/v2";
xmlns:request="http://www.apache.org/1999/XSP/Request";
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
xmlns:fragmentation="http://localhost/fragmentation";>







String frag_query = null;





   

frag_query = "select e.idensemble as id, e.xml as xml from ensemble
e";


  
 foo

 
frag_query


   









   

   ...

 
  
   

   ...



I my XML file:
##





http://localhost/fragmentation";
  xmlns:esql="http://apache.org/cocoon/SQL/v2";
  ...
>
...

...

...


> I've read through the ESQL docs and looked at many ESQL examples but I
> havent found an example which uses ESQL in the stylesheet 
> instead of the XML
> document.  I added the XML namespace for ESQL in my stylesheet tag:
> 
>   xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
>  xmlns:esql="http://apache.org/cocoon/SQL/v2";
>  xmlns:xsp="http://www.apache.org/1999/XSP/Core";
> >
> ...
> 
> When I simply run esql tags in one of my templates it ignores 
> those tags and
> just prints out the data (like XSP isn't processing the ESQL tags).
> 
> I think it may have something to do with the  tags 
> or something.
> I poked around in some of the sample code, in the newsgroups 
> and the mailing
> list to try and find where someone used esql in their 
> stylesheet but couldnt
> find anything.
> 
> Any help would be appreciated!  Oh, and Olivier Jeulin, thanks for the
> pointer to the auth taglib - that works great!
> 
> - Brent
The auth taglib is in the list of "3rdparty" on cocoon's site
Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: [c1] xsp:logic compiling

2001-08-03 Thread JEULIN Olivier

Take a look at the auth taglib (http://ulim.cocoonhost.com/)

-Message d'origine-
> De : Brent L Johnson [mailto:[EMAIL PROTECTED]]
> Envoyé : vendredi 3 août 2001 00:07
> À : [EMAIL PROTECTED]
> Objet : [c1] xsp:logic compiling
> 
> 
> I'm fairly new to Cocoon - but I've been muddling through it 
> now for a few
> days.  But I'm hoping this isn't too big of a newbie 
> question, but I didn't
> find any answers in the mailing list archives, the 
> newsgroups, or the web.
> 
> * Cocoon 1.8.2 with Tomcat
> 
> I've created an XSL file which is working fine so far (it's a 
> basic login)
> with it's XML instance document counterpart.  When the user submit a
> login/pw form, it submits back to the same XML file (which in 
> my case is
> index.xml).  Here's a quick snip of the XSL code:
> 
>   
>  name="cocoon-process">type="xsp"
>  name="cocoon-format">type="text/html"
>  xmlns:xsp="http://www.apache.org/1999/XSP/Core";>
> 
> 
> 
> What I want to do is fairly simple.  Check to see if the form has been
> submitted, by checking for the "login" parameter.  So here is 
> what I changed
> the code to:
> 
>   
>  name="cocoon-process">type="xsp"
>  name="cocoon-format">type="text/html"
>  xmlns:xsp="http://www.apache.org/1999/XSP/Core";>
> 
> if (request.getParameter("login.x") == null) {
> 
>  the rest of the HTML which shows the login form 
> 
> } else {
> ... check username exists, etc
> response.sendRedirect("main.xml");
> }
> 
> 
> The problem seems to be how Cocoon is generating the java 
> code.  It seems as
> though if I put the  tags before the  tag it 
> puts the code
> outside of any method in the /* User Class Declarations */ 
> part which is, of
> course, not valid Java syntax if I'm doing an "if" statement.
> 
> If I move the  after the  tag my if 
> statement goes into the
> populateDocument() method (which is OK - but after an HTML 
> tag has been sent
> to the browser I can no longer redirect).
> 
> Can anyone give me a suggestion on how I should handle the redirects??
> 
> Also, how "full-featured" is Cocoon2?  It looks as though C2 
> has some nifty
> logicsheets for request and response objects (of which, by 
> the way, it seems
> as though I can use the request logicsheet in C1 and 
> 
> seems to still work fine...  on the other hand does 
> not).  With
> those logic sheets I could just use an  on the 
> parameter and
> then send the redirect.
> 
> I'm working on a live site for a client though, so stability 
> is an important
> issue.
> 
> Anyways, any help would be appreciated, thanks,
> 
> - Brent

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Connecting database and XML pages

2001-08-01 Thread JEULIN Olivier

> Thank you, Olivier, you helped me to get started!
You're welcome

> I'm running c1.8.2 so I implemented your example.
> 
> But when I try to open the pages, I get a 
> java.lang.ClassNotFoundException.
> The same happens when I try to open pages from 
> cocoon/samples/sql. I guess I
> have done a little and ridiculous mistake somewhere, but I 
> need some hints
> as to what could be wrong...
> 
> Thanx for your time!
> /Anne Marie
I'm using tomcat, and I put mm.mysql-2.0.4-bin.jar with all the other .jar
of cocoon in the /var/tomcat/lib (linux)
Be sure you have the 'bin' version, not the 'src', of the driver there.
The way to tell your servlet engine to find the file may vary
Also, take a look at the mail list archive, I think that there was a
discussion about the configuration of mysql with cocoon.
(The link to the JDBC driver is http://mmmysql.sourceforge.net)
And be carefull with your request: if there is an error (syntax, invalid
column name), I get no exception or message...
Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: xinclude before xslt, how retrieve the url ?

2001-08-01 Thread JEULIN Olivier

Well, in fact, the best way (it's more clean) is to use xpointer (see the
'xinclude' subdirectory in the samples) and the file xinclude_poem.xml

> > Your index could also look like:
> > 
> > 
> > ...
> > 
> > and you could load what you want using document({@url},title) 
> > in a template
> > matching item

> Thanks for your answer, the 2d solution is what i want (i don't want to
> repeat the href attribute twice).

Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: xinclude before xslt, how retrieve the url ?

2001-07-31 Thread JEULIN Olivier

what about 

  


But if the files are big, wouldn't it be better to use
document(page1.xml,title) to get exactly the titles?

Your index could also look like:


...

and you could load what you want using document({@url},title) in a template
matching item

Olivier

P.S. pas trop chaud à Sophia-Antipolis ;) ?

> -Message d'origine-
> De : Ludovic Maitre [mailto:[EMAIL PROTECTED]]
> Envoyé : lundi 30 juillet 2001 19:56
> À : Cocoon Users
> Objet : xinclude before xslt, how retrieve the url ?
> 
> 
> Hello Cocoon users,
> 
> I want to include some files in a xml file in Cocoon 1.8.2.
> For example this index.xml :
> 
> 
> 
> 
> 
> 
> 
> http://www.w3.org/1999/XML/xinclude"; >
> 
> 
> 
> 
> 
> and i want to apply a xsl who transform all these includes in 
> a summary,
> a list of all the title elements contained in the included XML pages
> with 
> an hyperlink to these pages. 
> 
> Anybody know how i can retrieve the url of the included files from
> index.xsl 
> for generate a  tag ? 
> [i have test with the document() function of XSLT, for obtaining the
> URI-basename
> of the nodes that i traverse but i haven't succedeed to obtain the url
> of the nodes]
> 
> Obviously, the purpose is to make a menu, perhaps it's not 
> the good way 
> if this is the case i appreciate any suggestion.
> 
> Thanks per advance and good evening (or day), 
> 
> -- 
>  [EMAIL PROTECTED]
> 
>  INRIA - 2004 route des lucioles - BP 93Tel: (33/0) 4 92 38 50 41
>  06902   SOPHIA-ANTIPOLIS cedex (France)Fax: (33/0) 4 92 38 76 02

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: xsl transfromation.

2001-07-31 Thread JEULIN Olivier

In this case, there's a problem with the body tag, opened in a template and
closed in another one.
There are also 3 (!) templates matching "guide"... It's useless, only the
1st or last one will be used (I don't remember if this is in the spec or
XSLT engine dependant)

I would advise you to use identation when writing templates. This kind of
error will be easier to track... (see discussion about xsl editing;
personnaly, I'm using cooktop -- it can also validate you stylesheets)

Also, don't expect too much of cocoon's error message: they're quite useless
as you can see here. Use a xml/xsl validator to find the right bug.

Olivier

> -Message d'origine-
> De : Kazi the P i R @ t {- [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 31 juillet 2001 06:24
> À : [EMAIL PROTECTED]
> Cc : [EMAIL PROTECTED]; Lim Huat Heng
> Objet : xsl transfromation.
> 
> 
> System: Win 98
> Servlet Engine: Tomcat (standalone) 3.2.1
> XML Framework: Cocoon 1.8.2
> Trouble:
> I was just trying out an xsl transformaiton of a static xml page i
> created... but then when i called the page from the browser 
> the following
> error comes up -
> 
> 'org.apache.cocoon.processor.ProcessorException: Could not associate
> stylesheet to document:  error reading
> C:\Tomcat\webapps\cocoon\newProd\guide-html.xsl:
> org.xml.sax.SAXParseException: The element type "xsl:template" must be
> terminated by the matching end-tag "".'
> 
> I just checked the  appears that
> all the tags were closed properly.
> 
> The XSL file -
> 
> 
> http://www.w3c.org/1999/XSL/Transform";
> version="1.0">
> 
> 
> A Guide to the Search Utility
> 
> 
> 
>  name="cocoon-format">type="text/html"
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>  valign="middle">
>  select="image"/>
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> form more information contact the person 
> below:
> 
> 
> 
> 
> 
> 
> 
> 
> 
> My DTD -
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Connecting database and XML pages

2001-07-31 Thread JEULIN Olivier

As usual here, you forgot to tell which version of cocoon you're using...
Here is an (short!) example of what you can do with C1.8.2 (it may slightly
differ with C2):

http://www.apache.org/1999/XSP/Core";
xmlns:auth="http://ulim.cocoonhost.com/auth";
xmlns:request="http://www.apache.org/1999/XSP/Request";
xmlns:session="http://www.apache.org/1999/XSP/Session";
xmlns:foo="http://localhost/foo";
xmlns:esql="http://apache.org/cocoon/SQL/v2";
xmlns:util="http://www.apache.org/1999/XSP/Util";
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
xmlns:xinclude="http://www.w3.org/1999/XML/xinclude";
>

[...]


foo  


  
select b.ref as ref b.quantite as nb
from basket b
where b.id = 

  

  
  




 
  

   

  




[more ...]


You can retrieve different kind of data, even XML (read the doc, and
esql.xsd in the samples/sql directory)

##

You can connect directly to the DB (with user ID & pwd) or, much better,
using a connection pool.
Here is mine (from cocoon.properties), using a DB named foo:

# Turbine DB Connection Pool


# These are your database settings, look in the
# org.apache.turbine.util.db.pool.* package for more information.

processor.xsp.pool.database.foo.driver=org.gjt.mm.mysql.Driver
processor.xsp.pool.database.foo.url=jdbc:mysql://your.mysql.server/foo
processor.xsp.pool.database.foo.username=foouser
processor.xsp.pool.database.foo.password=foopwd
processor.xsp.pool.database.foo.maxConnections=5
processor.xsp.pool.database.foo.expiryTime=360
[...]
# These are the supported jdbc-drivers and their adaptors.
# These properties are used by the DBFactory.
processor.xsp.pool.database.adaptor=DBMM
processor.xsp.pool.database.adaptor.DBMM=org.gjt.mm.mysql.Driver

You will need the JDBC adaptater for mysql (see the official mysql site,
sun's JDBC section, or search the list's archives about it)

HTH,
Olivier

> -Message d'origine-
> De : [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 31 juillet 2001 09:08
> À : [EMAIL PROTECTED]
> Objet : Connecting database and XML pages
> 
> 
> Hi,
> 
> I have a mySQL database. I also have a web server: 
> Apache-Tomcat-Cocoon. I
> want to make web pages written in XML, transformed to HTML or 
> WML by the
> help of Cocoon. These pages will serve as an interface to the 
> database.
> 
> What is the best way to connect the database with the XML 
> pages? My users
> should be able to read and write in the database.
> 
> Any tips, suggestions, experiences and examples are greatly 
> appreciated!
> 
> /Anne Marie

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: C1: problem with FOR STATEMENT

2001-07-27 Thread JEULIN Olivier

Take a look at the generated java file around the line 6735: you will
probably see that part of your code is interpreted as text (-> put in a text
node!).
Surround your code with another  inside 

-Message d'origine-
De : Simone Bortolaso [mailto:[EMAIL PROTECTED]]
Envoyé : vendredi 27 juillet 2001 12:27
À : [EMAIL PROTECTED]
Objet : C1: problem with FOR STATEMENT


Why cocoon take this error 
Java.lang.Exception: XSP Java Compiler: Compilation failled for
_myindex.java
6735: Undefined variable: numcurves
xspExpr(numcurves,document)   

in the nested statement:


 


for(int subsection = 0; subsection < 2; subsection++){
   http://pc000450:8080/sla/images/indent15x15.gif";>
 
viewer.getSubSectionLabel(subsection,u)

 int numTotReport =
viewer.getNumReport(subsection,u);
 for( int numreport = 0; numreport < numTotReport
; numreport++){   
  int numTotCurves =
viewer.getNumCurves(subsection,u,numreport);   
  for(int numcurves = 0; numTotCurves < 2;
numcurves++){  
   http://pc000450:8080/sla/servlet/otdr?id=";>   
  OTDR trace
 
u
 
numcurves
  
   
  } 

 } 
  
  } 
   


-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: esql:query + esql:parameter bug

2001-07-19 Thread JEULIN Olivier

Here is an example of what I did.
This works inside a "xsp:logic" tag... In your case, you may use xsp:logic
instead of xsp:expr

* using a variable (_ensemble) :

if ( != null) {
  [some code here]
...
  
select i.idtitle, t.xml
from _ensemble identifiant i, title t
where i.idtitle = t.idtitle _whichGroup + _like
  


* using a taglib: this is the same thing, because taglib elements are
expanded to *java code*
just replace _ensemble above with 

Olivier

> -Message d'origine-
> De : Arnaud Bienvenu [mailto:[EMAIL PROTECTED]]
> Envoyé : jeudi 19 juillet 2001 15:21
> À : [EMAIL PROTECTED]
> Objet : esql:query + esql:parameter bug
> 
> 
> If I write, for example :
> 
>  select * from space where person like  type="string">Alex
>  ...
> (I known I don't need the esql:parameter tags here, but see below...)
> 
> Then I get an error :
> Error compiling index_xsp: Line 303, column 37: ')' expected.
> 
> Actually, the generated code is :
> try {
>   _esql_query.prepared_statement.setString(1,
>  this.characters("Alex"););
> }
> 
> which is obviously incorrect. The generated code gets more 
> broken if you use
> something like
> 
> 
> I think this is a big problem, and if some developer manage 
> to fix it, he
> would be a real man (or woman)...
> 
> -- 
> Arnaud Bienvenu
> http://www.generasound.com/
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Doubt in aplying stylesheet using Cocoon's xslt processor.

2001-07-19 Thread JEULIN Olivier

Use 

You may find http://www.dpawson.co.uk/xsl/sect2/sect21.html usefull for this
king of questions
Olivier

> -Message d'origine-
> De : Hema Rajan [mailto:[EMAIL PROTECTED]]
> Envoyé : jeudi 19 juillet 2001 11:52
> À : [EMAIL PROTECTED]
> Objet : Doubt in aplying stylesheet using Cocoon's xslt processor.
> 
> 
> 
> Hi there!
> 
> We have to match an element which is in 4 or 5 th level from 
> the current
> level.  Is there anyway to find out this element without giving the
> absolute/relative path in the xsl?
> 
> For example, our XML file is as follows:
> 
> 
>   
>   
>   
>   
>   
>   
> 
>   
>   
>   
>   
>   
>   
> 
> 
> In our stylesheet we have the following template:
> 
> 
>   
>   
>   
>   
>   
>   
>name="{@item}"
> value="$({@item})"/>
>   
>   
>   
>   
> 
> 
> The above template works fine only if the  element is 
> directly below
> the  tag.  It will not work if the  element is 2 or 3
> levels below the  tag.  We tried replacing the
> "" line with
> "".  Even this did not 
> work.  Any
> suggestions?  

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: include xsp:expr inside attributes?

2001-07-17 Thread JEULIN Olivier

Or:

   
foo.getBar()"/>
   


> -Message d'origine-
> De : Anthony Diodato [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 17 juillet 2001 17:44
> À : '[EMAIL PROTECTED]'
> Objet : RE: include xsp:expr inside attributes?
> 
> 
> 
>  Element mynode = document.createElement("mynode");
>  mynode.setAttribute("myattr", foo.getBar());
>  xspCurrentNode.appendChild(mynode);
> 
> 
> -Original Message-
> From: Seth Ladd [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, July 17, 2001 11:39 AM
> To: [EMAIL PROTECTED]
> Subject: include xsp:expr inside attributes?
> 
> 
> Hello,
> 
> I'm not sure how to accomplish the following.  I was hoping 
> someone would 
> point me in the right direction?
> 
> I would like to do the following:
> 
> 
> 
> But, of course, that is not wellformed XML.  Is there a way 
> to accomplish 
> that is XSP?
> 
> Thanks very much,
> Seth

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-12 Thread JEULIN Olivier

RPM of C1.8.2-2  + tomcat 3.2.1 + apache 1.3.12-25 on redhat 7.?

> -Message d'origine-
> Tell me Olivier, what platform are you using?
> 
> Paolo.

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP Problem - UnsupportedEncodingException

2001-07-12 Thread JEULIN Olivier

Hello,
this a bit OT... And the message from the compiler is quite explicit
In java, you must declare all exception in the prototype of the function; in
this case, 
you should enclose your code in a try/catch bloc

> -Message d'origine-
> Hello,
> 
> i have following Problem with xsp:logic and getBytes
> 
> my code is:
> --
> 
>  xmlns:xsp="http://apache.org/xsp";
> xmlns:xsp-request="http://apache.org/xsp/request/2.0";>
> 
>
>  
>   String saveAs = request.getParameter("saveAs");
>   String name_enc = new String(saveAs.getBytes("8859_1"));
>   System.out.println (name_enc);
> 
>  
> 
>  
>  
>
> 
> 
> --
> 
> when i enter an encoding String in getBytes(), i will get 
> following
> error with cocoon:
> Exception java.io.UnsupportedEncodingException must be 
> caught, or it must be
> declared in the throws clause of this method.
> 
> how can i get the german characters, because the characters, which are
> printed with System.out.println, are not the same i entered 
> as parameter.
> 
> 
>   Georg Schmitt

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-12 Thread JEULIN Olivier

> > This is weird, because the java file and the counter change, 
> > so the request
> > *is* processed by cocoon and it should reflect the text 
> > change (my version
> > works fine on this part: java file modified, class recompiled).
> 
> On my system it's the same: java file gets modified and the class is
> recompiled. Both have the same date/time.
> 
> -rw-r--r--1 www-data www-data10479 Jul 12 14:11 
> _clean_page.class
> -rw-r--r--1 www-data www-data22772 Jul 12 14:11 
> _clean_page.java

looks OK

> > Try to delete _clean-page.* from your repository *without* 
> > restarting cocoon
> > and reload the page.
> 
> Done! WITHOUT restarting Cocoon, _clean-page.* are recreated: 
> I reloaded the
> page and the old clean-page.xml is showed with the counter 
> going on from
> where I left it last time!

!!!
I dunno... this shouldn't happen (AFAIK)
I had this kind of trouble before setting the repository to an absulute
path, but then the .class/java weren't created at all.
If you reload cocoon, without deleting _clean-page.*, what happens to these
files, and what is the result ?

> What the heck is happening? :(
> 
> Paolo.
bad karma ? ;)
Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: How to set session attribute correctly

2001-07-12 Thread JEULIN Olivier

I strongly encourage you to try all your ideas and to look at the generated
java file...
It's the best way to see what really happens.
Anyway, here are my personal feelings (I work with C1)... But I'm not a
cocoon guru yet :) (the code will tell you the all truth!)


> -Message d'origine-
> De : Zeljko Rajic [mailto:[EMAIL PROTECTED]]
> Envoyé : jeudi 12 juillet 2001 13:56
> À : [EMAIL PROTECTED]
> Objet : How to set session attribute correctly
> 
> 
> Hi Cocoon users,
> 
> I'm wondering how to set a session attribute correctly using the
>  tag.
> 
> For example I create an instance of an own object:
> 
> 
>MyObject theInstance = new MyObject();
> 
> 
> 
> Later in the XSP document I'd like to add this instance to 
> the session using
> the  tag. Now I'm not sure what's 
> the correct way
> to do so as there are several possibilites:
> 
>  name="MyAttribute">theInstance

creates a text node containing "theInstance", not what you want

> or:
> 
>  name="MyAttribute">theInstance on:set-attribute>

good

> And then, how to I correctly set a string value? Like this:
> 
> Some text 
> !!
> 
> or is this the correct way:
> 
> Some text
> !!

session variables contain Object... look at the code to see what really
happens

> And by the way, is this kind of expression allowed:
> 
> 
>
>   if ( "object".equals( name="MyParam"/>)
>   {
>  theInstance
>   }
>   else
>   {
>   Some Text !!
>   }
>
> 

yes, it should work, but I don't see why you put theInstance inside
xsp:expr...
Everything in xsp:logic is treated as code, except when you use xsp:content

> Any kind of comments are welcome !!
> 
> -  Zeljko
> 
> 
> PS: Yes I know, I could simply use the 
> 'session.setAttribute(...)' method, but
> I'd like to use the  tag.

good idea, I do it myself :)
Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-12 Thread JEULIN Olivier

This is weird, because the java file and the counter change, so the request
*is* processed by cocoon and it should reflect the text change (my version
works fine on this part: java file modified, class recompiled).

Try to delete _clean-page.* from your repository *without* restarting cocoon
and reload the page.

The problem is that cocoon runs the wrong version of the compiled class, but
if the java file reflects the text change, normally cocoon also recompiles
this class...
Check the dates: the .class should always be older than the .java

> (...)

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-12 Thread JEULIN Olivier

Does the java file take your modification into account ?
What happens when you reload the xml file just after the modification? Does
the counter change ?
If it's immediate, the page is in cache somewhere: try to use netscape with
memory & disk cache size=0.


> -Message d'origine-
> De : Dongilli Paolo [mailto:[EMAIL PROTECTED]]
> Envoyé : jeudi 12 juillet 2001 09:33
> À : '[EMAIL PROTECTED]'
> Objet : RE: XSP with Cocoon 1.8.1 - Cache Problem?
> 
> Could you help me please with the further checks?
> 
> After restarting Cocoon and changing "clean-page.xml" I see 
> the modification
> "FOO ...".
> Now, if I change it again without restarting Cocoon, I see 
> always the old
> version of "clean-page.xml".
> 
> Thanks a lot,
> Paolo.

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-11 Thread JEULIN Olivier

> > 2) load this page in your browser. (At this point, the page 
> > prints 'FOO  Hi,
> > I'm your ...' in my browser)
> 
> OK.

Do you see 'FOO ...' in your browser ? If not, what is the *complete* path
to the _clean-page.java file and the *complete* path to your clean-page.xml
file ? They should look like the same at the end (with '_' for java)

> 
> > 3) take a look in your repository and check the 
> > '_clean-page.java' to see if
> > its date of modification is the current time and date. If so 
> > search in it
> > for the string 'FOO'. You should find it, if the page is recreated
> > correctly.
> 
> OK. _clean-page.java created and it contains the modicication "FOO".
> 
> > And let's see what happens (please copy what you put in 
> > cocoon.properties
> > for the repository path)
> 
> processor.xsp.repository = /usr/share/java/repository
> 
> Waiting for further steps.
> 
> Thanks,
> Paolo.

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-11 Thread JEULIN Olivier

OK, let's try step by step :
0) restart cocoon; delete all the files named '_clean-page.*' in your
repository 
1) in the (your servlet engine path)/webapps/cocoon/samples/xsp directory,
change the file 'clean-page.xml' by adding FOO to the 1st paragraph like
this:
FOO Hi, I'm your ...
2) load this page in your browser. (At this point, the page prints 'FOO  Hi,
I'm your ...' in my browser)
3) take a look in your repository and check the '_clean-page.java' to see if
its date of modification is the current time and date. If so search in it
for the string 'FOO'. You should find it, if the page is recreated
correctly.
And let's see what happens (please copy what you put in cocoon.properties
for the repository path)
Olivier

> -Message d'origine-
> De : Dongilli Paolo [mailto:[EMAIL PROTECTED]]
> Envoyé : mercredi 11 juillet 2001 14:52
> À : '[EMAIL PROTECTED]'
> Objet : RE: XSP with Cocoon 1.8.1 - Cache Problem?
> 
> 
> OK, I upgraded to C1.8.2.
> Same problem: .java and .class files are re-created in the 
> repository, but
> in the browser after reloading I see the old version of 
> "clean-page.xml".
> In the original cocoon.properties I just changed the 
> repository dir to an
> absolute path. That's all.
> 
> Paolo.
(...)

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-11 Thread JEULIN Olivier

Well, it could, that's why I advised you to upgrade: at least, we could
compare comparable things.

> -Message d'origine-
> De : Dongilli Paolo [mailto:[EMAIL PROTECTED]]
> Envoyé : mercredi 11 juillet 2001 12:16
> À : '[EMAIL PROTECTED]'
> Objet : RE: XSP with Cocoon 1.8.1 - Cache Problem?
> > Yes, of course, if you java file has changed, you'll (well, 
> > should) see the
> > modification.
> > I've added "foo" in the "I've bee requested...", and it 
> > appears in the java
> > file, as well as in the html page generated...
> 
> Is it possible that Cocoon internal cache isn't updated after 
> the creation
> of the new .java and .class files?
> Could it be a problem of C1.8.1?
> 
> Paolo.
(...)

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-11 Thread JEULIN Olivier

Yes, of course, if you java file has changed, you'll (well, should) see the
modification.
I've added "foo" in the "I've bee requested...", and it appears in the java
file, as well as in the html page generated...
Olivier

 -Message d'origine-
> De : Dongilli Paolo [mailto:[EMAIL PROTECTED]]
> Envoyé : mercredi 11 juillet 2001 11:46
> À : '[EMAIL PROTECTED]'
> Objet : RE: XSP with Cocoon 1.8.1 - Cache Problem?
> 
> 
> > Well, you should upgrade to C1.8.2 (latest versions always 
> > have less bugs,
> > if this is one).
> > This example works fine (the page counter is incremented 
> > everytime I reload
> > the page) with C1.8.2 NS, lynx and IE...
> 
> But have you tried to modify for example the text of 
> clean-page.xml and to
> reload it then?
> In my case the counter goes on and I continue to see the old version. 
> Please let me know.
> 
> Thanks a lot,
> Paolo.
(.)

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-11 Thread JEULIN Olivier

Well, you should upgrade to C1.8.2 (latest versions always have less bugs,
if this is one).
This example works fine (the page counter is incremented everytime I reload
the page) with C1.8.2 NS, lynx and IE...

(...)
> > It's probably a navigator's cache problem. Especially with IE 
> > (you can't
> > deactivate the cache).
> > Try to clear your navigator's cache
> 
> I tried with Netscape 4.76, with Lynx and I still see the old 
> version of the
> document. 
> The sole solution is to restart Cocoon in order to see the 
> modifications. 
> I don't want to restart Cocoon each time I modify an xml 
> (xsp) document.
> Please help me fix this.
> 
> Thank you,
> Paolo.
> > > -Message d'origine-
> > > De : Dongilli Paolo [mailto:[EMAIL PROTECTED]]
> > > Envoyé : mardi 10 juillet 2001 20:17
> > > À : '[EMAIL PROTECTED]'
> > > Objet : XSP with Cocoon 1.8.1 - Cache Problem?
> > > 
> > > 
> > > I tried to modify just some text in the sample file 
> > > "clean-page.xml" in the
> > > samples/xsp directory of Cocoon 1.8.1.
> > > 
> > > I reloaded the page in the browser and the java files are 
> > > newly created and
> > > compiled in the repository but the output (after the XSLT) is 
> > > always the
> > > same I had before the modification.
> > > 
> > > I read the FAQ first but I didn't find a solution.
> > > 
> > > Hopefully somebody have some idea about this.
> > > 
> > > Thanks a lot,
> > > Paolo.

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: XSP with Cocoon 1.8.1 - Cache Problem?

2001-07-11 Thread JEULIN Olivier

It's probably a navigator's cache problem. Especially with IE (you can't
deactivate the cache).
Try to clear your navigator's cache

> -Message d'origine-
> De : Dongilli Paolo [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 10 juillet 2001 20:17
> À : '[EMAIL PROTECTED]'
> Objet : XSP with Cocoon 1.8.1 - Cache Problem?
> 
> 
> I tried to modify just some text in the sample file 
> "clean-page.xml" in the
> samples/xsp directory of Cocoon 1.8.1.
> 
> I reloaded the page in the browser and the java files are 
> newly created and
> compiled in the repository but the output (after the XSLT) is 
> always the
> same I had before the modification.
> 
> I read the FAQ first but I didn't find a solution.
> 
> Hopefully somebody have some idea about this.
> 
> Thanks a lot,
> Paolo.

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Executing XML inside XML

2001-07-10 Thread JEULIN Olivier

There's a little bug in a processor (see the maillist archive for more info
on this): to use xinclude, you must use the following tag:

(it works for me and C1.8.2)

> -Message d'origine-
> De : Carloz Alaniz [mailto:[EMAIL PROTECTED]]
> Envoyé : lundi 9 juillet 2001 22:23
> À : [EMAIL PROTECTED]
> Objet : Re: Executing XML inside XML
> 
> 
> Olivier,
> I tried your suggestion but it does not work. 
> This is a more detailed explanation
> This is what my "c.xml" file looks like
> 
> 
> 
> http://www.w3.org/1999/XML/xinclude";>
>   
> 
> 
> 
> This is what my "a.xml" file looks like
> 
> 
> 
> 
> 
> 
>   this is my title
>   revision.revision
>   today
>   My Group
>   My Team
> 
> 
> 
> This is what my "a.xsl" file looks like
> 
> 
>  xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
>  
> 
>  
> (header)
>  
> 
>  
>  
>
>  
>Rev 
>  
>  
>
>  
>  
>  
>  
>
>  
>  
>Rev 
>  
>  
> 
>  
> 
> 
> 
> 
> ~~
> I just get a blank gray screen as a result of this.
> How come "a.xml" is not executed when "c.xml" is called ??? 
> What am I doing wrong. 
> Please help me!
> 
> ~carloz
> 
> JEULIN Olivier wrote:
> > 
> > to use xinclude you'll need:
> >  to call the processor,
> > xmlns:xinclude="http://www.w3.org/1999/XML/xinclude"; in 
>  tag,
> >  xinclude:href="your_filename.xml" /> where you
> > want to include a file
> > 
> > The only drawback is that if you use xsp, the content of 
> your included files
> > will be "static", that is if you change them, you won't see 
> the modification
> > until you rebuild the c.java file (by changing its date, 
> for example).
> > Otherwise, use  (and add
> > xmlns:util="http://www.apache.org/1999/XSP/Util"; to the 
> xsp:page tag)
> > Olivier
> > 
> > > -Message d'origine-
> > > De : Carloz Alaniz [mailto:[EMAIL PROTECTED]]
> > > Envoyé : lundi 9 juillet 2001 18:46
> > > À : [EMAIL PROTECTED]
> > > Objet : Executing XML inside XML
> > >
> > >
> > > Hi I am still trying to figure this out. I need help.
> > >
> > > This is what I want to do. I have a file lets name it a.xml
> > > which calls
> > > a.xsl which  produces an HTML heading in your browser.
> > >
> > > I have another file named b.xml which calls b.xsl and 
> produces an HTML
> > > footer.
> > >
> > > I am trying to create another another file named c.xml which
> > > calls both
> > > a.xml and b.xml and displays them together into a single HTML page
> > > displaying the header at the top and the footer at the 
> bottom. Someone
> > > suggested Xinclude but I can't get it to work.
> > >
> > > I am looking forward for you all cocooner's help.
> > >
> > > Best Regards,
> > > Carloz

-
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Executing XML inside XML

2001-07-09 Thread JEULIN Olivier

to use xinclude you'll need:
 to call the processor,
xmlns:xinclude="http://www.w3.org/1999/XML/xinclude"; in  tag,
 where you
want to include a file

The only drawback is that if you use xsp, the content of your included files
will be "static", that is if you change them, you won't see the modification
until you rebuild the c.java file (by changing its date, for example).
Otherwise, use  (and add
xmlns:util="http://www.apache.org/1999/XSP/Util"; to the xsp:page tag)
Olivier

> -Message d'origine-
> De : Carloz Alaniz [mailto:[EMAIL PROTECTED]]
> Envoyé : lundi 9 juillet 2001 18:46
> À : [EMAIL PROTECTED]
> Objet : Executing XML inside XML
> 
> 
> Hi I am still trying to figure this out. I need help. 
> 
> This is what I want to do. I have a file lets name it a.xml 
> which calls
> a.xsl which  produces an HTML heading in your browser. 
> 
> I have another file named b.xml which calls b.xsl and produces an HTML
> footer. 
> 
> I am trying to create another another file named c.xml which 
> calls both
> a.xml and b.xml and displays them together into a single HTML page
> displaying the header at the top and the footer at the bottom. Someone
> suggested Xinclude but I can't get it to work. 
> 
> I am looking forward for you all cocooner's help. 
> 
> Best Regards,
> Carloz
> 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: esql problem

2001-07-06 Thread JEULIN Olivier

It seems you should put it inside xsp:logic like this

 rowNum = ;

(if C2 is a bit like C1 ;) )
> -Message d'origine-
> De : Marco Spinetti [mailto:[EMAIL PROTECTED]]
> Envoyé : vendredi 6 juillet 2001 15:08
> À : [EMAIL PROTECTED]
> Objet : R: esql problem
> 
> 
> I saw prova_xsp.java and I found this code:
> 
> while (_esql_query.resultset.next()) {
> this.characters("\n\t\t\t\t\trowNum = ");
> (_esql_query.resultset.getInt("result"))
> this.characters(";\n\t\t\t\t\t");
> if (_esql_connection.use_limit_clause ==
> 0 && _esql_query.max_rows != -1 &&
> _esql_query.position -
> _esql_query.skip_rows ==
> _esql_query.max_rows - 1) {
>   _esql_query.position++;
>   break;
> }
> _esql_query.position++;
>   }
> 
> but I don't see any error. Am I mistake?
> Marco
> 
> 
> - Original Message -
> From: JEULIN Olivier <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, July 06, 2001 2:56 PM
> Subject: RE: esql problem
> 
> 
> I'm using C1, it was a guess for C2...
> Let's try again :) :
>  as Chris tolds you, take a look at the generated java file, 
> I bet the ';'
> is causing this error (taglibs' elements generate java code 
> and are often
> nested in functions call)
> Olivier
> 
> > -Message d'origine-
> > De : Christian Haul [mailto:[EMAIL PROTECTED]]
> > Envoyé : vendredi 6 juillet 2001 14:49
> > À : [EMAIL PROTECTED]
> > Objet : Re: esql problem
> >
> >
> > On 06.Jul.2001 -- 02:30 PM, JEULIN Olivier wrote:
> > > Well, esql:get-int needs a column name,
> > > so try:  "select count(*) as thecount from..."
> > > and use: 
> >
> > That's not true. It takes either a label or a number. So
> >  should work (and it's translated 
> correctly
> > to _esql_query_resultset.getInt(1). Problem seems to be
> > something else.
> >
> > Marco, have a look at the generated source, line 4816
> >
> > /usr/local/home/siteadm/download/jakarta-tomcat-3.2.2/work/loc
> > alhost_8080%2Fcocoon/org/apache/cocoon/www/elenco/prova_xsp.java
> >
> > Chris.
> >
> > --
> > C h r i s t i a n   H a u l
> > [EMAIL PROTECTED]
> > fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 
> 
> 
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: esql problem

2001-07-06 Thread JEULIN Olivier

I'm using C1, it was a guess for C2...
Let's try again :) :
 as Chris tolds you, take a look at the generated java file, I bet the ';'
is causing this error (taglibs' elements generate java code and are often
nested in functions call)
Olivier

> -Message d'origine-
> De : Christian Haul [mailto:[EMAIL PROTECTED]]
> Envoyé : vendredi 6 juillet 2001 14:49
> À : [EMAIL PROTECTED]
> Objet : Re: esql problem
> 
> 
> On 06.Jul.2001 -- 02:30 PM, JEULIN Olivier wrote:
> > Well, esql:get-int needs a column name,
> > so try:  "select count(*) as thecount from..."
> > and use: 
> 
> That's not true. It takes either a label or a number. So 
>  should work (and it's translated correctly
> to _esql_query_resultset.getInt(1). Problem seems to be 
> something else.
> 
> Marco, have a look at the generated source, line 4816
> 
> /usr/local/home/siteadm/download/jakarta-tomcat-3.2.2/work/loc
> alhost_8080%2Fcocoon/org/apache/cocoon/www/elenco/prova_xsp.java
> 
>   Chris.
> 
> -- 
> C h r i s t i a n   H a u l
> [EMAIL PROTECTED]
> fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

-
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: esql problem

2001-07-06 Thread JEULIN Olivier

Well, esql:get-int needs a column name,
so try:  "select count(*) as thecount from..."
and use: 
Olivier
-Message d'origine-
Hi all, 
I have a question about esql. In my application I do a query "select
count(*) from." and I try to get the number result in this way:


elenco1

 query
 
 
 rowNum = ;
 
  

  

but cocoon2 gives me a error:

Invalid expression statement. (_esql_query.resultset.getInt(1)) ^ Line 0,
column 0:
/usr/local/home/siteadm/download/jakarta-tomcat-3.2.2/work/localhost_8080%2F
cocoon/org/apache/cocoon/www/elenco/prova_xsp.java:4816: Invalid expression
statement. (_esql_query.resultset.getInt(1)) ^ 

How can I take the result?

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: how to precompile the xsp ?

2001-07-03 Thread JEULIN Olivier

I'm working with C1, but I think XSP works the same way in C2:
XSP pages are compiled if
- the java file doesn't exist
- the XML file is newer than the java file
So, if you want to "precompile" XML files, you'll have to send a request for
those files to your web server.
I guess there are many way to achieve this by programming, but a quick way
could be to use an off-line navigating tool (wget, teleport pro, or
whatever) to request *.xml files
Have fun,
Olivier

> >I am developing a web application with Cocoon 2.
> > But the xsp's performance is not very good ( 
> > very slow ), so is it posible to precompile the xsp
> > file ? and may i know how to do it ?
> > 
> > Thank you.
> > 
> > From Kok Cho0n.

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: xsp & create-session="true" ?

2001-06-29 Thread JEULIN Olivier

Hi,
after your message I took a look to my own files: I had the same problem.
For me, it comes from an attribute copy in the auth taglib. I removed
 tags around the  template, so
it now look like:







...
...
You may have the same kind of problem somewhere in a stylesheet processed
before XSP compilation.

Hope this helps
Olivier
> -Message d'origine-
> I use Sessions in my xsp page an included the 
> create-session="true" in the
> xsp tag:
> 
>xmlns:xsp="http://www.apache.org/1999/XSP/Core";
>   xmlns:session="http://www.apache.org/1999/XSP/Session";
>   create-session="true" 
> >
> 
> But I still need to put in something like this:
> 
> 
>   session = request.getSession(true);
> 
> 
> is this ok? I thought the session is created by 
> create-session="true". I
> have Cocoon 1.8.2 running with Tomcat 3.2.2
> 
> Regards, Michael

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Does cache work in Cocoon 1.8.2 on Tomcat 3.2.1?

2001-06-26 Thread JEULIN Olivier

You're right, it doesn't work.
You've found a bug :-/
I haven't found it in the bug database (but you may want to check again; see
it in the 'bug database' section of cocoon's homepage).
I'll let you submit it, to take ll credit for it... Fame starts small ;)

> -Message d'origine-
> De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 26 juin 2001 17:27
> À : [EMAIL PROTECTED]
> Objet : RE: Does cache work in Cocoon 1.8.2 on Tomcat 3.2.1?
> 
> 
> Thank you very much. Now I managed to get the "from cache" in 
> the bottom :-) In 
> IE5.5 it is not enough to left-shift and reload - you have to 
> use the menu: 
> InternetOptions/DeleteFiles - now I know that.
> 
> But why can the same page NOT be cached in both IE and 
> Netscape? I understand 
> that the page could use a different stylseheet in Netscape 
> than IE and 
> therefore the cache has to get recalculated - so we have one 
> cache for Netscape 
> and another cache for IE. But only one of the browsers can 
> get a cache copy of 
> the page - this is the browser that asks for the page first 
> time after the 
> server is started. So is this normal behavior of Cocoon 
> cache? If this is 
> correct the cache in Cocoon 1.8.2 do only work for ONE device!
> 
> Thanks in advance
> /Bjarne
snip!

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Does cache work in Cocoon 1.8.2 on Tomcat 3.2.1?

2001-06-26 Thread JEULIN Olivier

Yup, "...served from cache in 1 ms..." 
My advices are:
1) (how could I forget this one) clear your browser's cache... ! I've try it
right now: IE was reading the old file. I bet 1 euro on this one ;)
2) if you have invalidated the cache while developping you app., restart
cocoon to be sure the new config file is loaded, and... that you're editing
the good one :) (in the WEB-INF of tomcat).
3) ... err ... blow up the all thing :)

Ol'
> -Message d'origine-
> De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 26 juin 2001 15:49
> À : [EMAIL PROTECTED]
> Objet : RE: Does cache work in Cocoon 1.8.2 on Tomcat 3.2.1?
> 
> 
> Thanks for your help. But I ran your sample-code, and it 
> works fine but the 
> page is NOT cached on my system - it outputs the HTML and this:
> 
> ""
> 
> So it was "served in", not "served from cache" - so any idea 
> of why this works 
> on your machine but not on my machine? On you system the text 
> is "served form 
> cache" - right?
> 
> I have tried this om Windows 2000 and Windows 98.
> 
> Thanks in advance
> /Bjarne

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Does cache work in Cocoon 1.8.2 on Tomcat 3.2.1?

2001-06-26 Thread JEULIN Olivier

Hi,
as explained in the "caching" section of the documentation, some contents
are
never cached, except if you tell cocoon to do so. If you use XSP, you'll
have to overload the 'hasChanged' method and put a .
Anyway, here is a small example that is cached for me, and with the very
same configuration:
as I only apply a XSLT transform (cacheable & doesn't invalidate the cache),
the page is cached just fine.
-xml file




  

  

  

  
-chainage-html.xsl

http://www.w3.org/1999/XSL/Transform";
version="1.0">

  type="text/html"
  
CHAINAGE



  



 non traité




 traité



 
   
 




Olivier
> -Message d'origine-
> De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Envoyé : mardi 26 juin 2001 14:12
> À : [EMAIL PROTECTED]
> Objet : Does cache work in Cocoon 1.8.2 on Tomcat 3.2.1?
> 
> 
> Hi,
> Does anyone have some source that gets cached by the Cocoon 
> 1.8.2 engine? If so 
> please send it to me, so I should se if it works in my 
> environment also. I have 
> been running Cocoon for some time, but have never seen the: 
> "" (no "from cache" ). Not even the 
> http://localhost:8080/cocoon/samples/hello/hello-page.xml 
> gets cached. My 
> cocoon.properties is below but maybe the problem is somewere 
> else. I have read 
> the "a brief guide to the cocoon cache system", and have 
> looked at some old 
> posted mails, but it didn't help me with getting the cache 
> work - I would 
> really like to see a simple exaple of a page that is cached - 
> so I will work 
> from there.
> 
> What am I doing wrong, any idea?
> 
> Thanks for any help in advance 
> /Bjarne
> 
> ##
> # Cache Managers #
> ##
> 
> # the default cache
> cache = org.apache.cocoon.cache.CocoonCache
> 
> #uncomment this to disable ALL page caching
> #cache = org.apache.cocoon.cache.NoCache
...

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: namespaces, document() and include

2001-06-21 Thread JEULIN Olivier

I've got something that does your inclusion, but don't ask my why you have
to do it this way :) !
I did it with xinclude, because document() returns nothing.
And if anyone knows another or a better way to do it, I'm very interested in
it :) !
(still haven't found out how cocoon does his stuff...)
Olivier

--
A.xsl
--

http://www.w3.org/1999/XSL/Transform";
xmlns:xsp="http://www.apache.org/1999/XSP/Core";
  xmlns:xinclude="http://www.w3.org/1999/XML/xinclude";
>









type="xinclude"
  
xinclude:
 
document:

 
apply-templates:
 
  



--
C.xsl
--

http://www.w3.org/1999/XSL/Transform";
xmlns:xsp="http://www.apache.org/1999/XSP/Core";>



  
foo
  



> -Message d'origine-
> De : Ruben [mailto:[EMAIL PROTECTED]]
> Envoyé : mercredi 20 juin 2001 21:55
> À : [EMAIL PROTECTED]
> Objet : namespaces, document() and include
> 
> 
> 
>  Hi everybody!
> 
>  I have found a very strange behaviour using XSL under Tomcat with
> Cocoon (in Linux) when I mix namespaces and includes.
> 
>  Suppose I have 4 documents:
> 
>   a) A.xml  -> procesed by A.xsl
>   b) A.xsl   ->  processes A.xml, acceses B.xml with 'document()' and
> includes C.xsl
>   c) B.xml  -> with some data I want to retrieve from A.xsl. Uses
> xsp:namespace
>   d) C.xsl   -> with some functions used by A.xsl
> 
>  The problem: when (and only when) I include C.xsl inside 
> A.xsl I cannot
> 
> access the data in B.xml; I get the error: 'cannot load 
> requested doc'.
> I've tried to reduce the files to the minimum, but I still 
> have the same
> 
> problem.
> 
>  Here you have the reduced examples of the files:
> 
> A.xml
> ---
> 
>  
>  
> 
>   
>  
> ---
> 
> A.xsl
> ---
> 
>  xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
> xmlns:xsp="http://www.apache.org/1999/XSP/Core";>
> 
> 
> 
> 
> 
>   
>  
>   
> 
> 
> 
> 
> ---
> 
> 
> B.xml
> ---
> 
> 
> 
> 
> 
>xmlns:xsp="http://www.apache.org/1999/XSP/Core";
>   xmlns:accesoBD="http://www.e-inteligentia.com/accesoBD";>
> 
>   the data I want to retrieve
> 
> 
> 
> ---
> 
> 
> C.xsl
> ---
> 
>  xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
> xmlns:xsp="http://www.apache.org/1999/XSP/Core";>
> 
> 
> 
> ---
> 
>  What am I doing wrong? Have I forgotten to declare a namespace or
> something? Is it a Cocoon problem? I would really appreciate any help,
> thank you in advance...
> 
> 
> 
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Strange Caching issues

2001-06-21 Thread JEULIN Olivier

Restarting cocoon clears the cache.
However, you should also clear your browser's cache, and if your page is a
xsp one, try to delete the message.* files in your repository directory.

Olivier
> -Message d'origine-
> De : Mark McGettrick [mailto:[EMAIL PROTECTED]]
> Envoyé : jeudi 21 juin 2001 00:57
> À : [EMAIL PROTECTED]
> Objet : Strange Caching issues
> 
> 
> Tomcat 3.2.1 with Cocoon 1.8.2
> 
> there is a file "message.xml" that uses "message.xsl"...
> before two days ago it was using "msg.xsl".
> 
> for the last two days the xml file has been using the correct 
> xsl file...
> 
> so, i just restarted tomcat because of a configuration change 
> and now the
> messages.xml has reverted to using the old msg.xsl. to make 
> things weirder,
> the messages.xml file clearly states "message.xsl".
> 
> why is cocoon suddenly confused?
> why won't it read the existing file to figure out which xsl to use?
> how do i "wipe the cache"?
> 
> the reason i think it's a cache issue is: if i rename the xml file it
> suddenly switches back to normal operation.
> 
> help!
> 
> -mark
> 
> 
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Xsl Formatting

2001-06-15 Thread JEULIN Olivier

I'm using Stylus 2.0. Althought it's not a WYSIWYG editor the way you (we?)
want, it helps stylesheet editing: you can see the effect of your templates
in real time, all the templates can be accessed in a scroll list,
auto-completion...
Here is a 30 days free evaluation:
http://www.exceloncorp.com/products/excelon_stylus.html

Hope this helps a little.
Olivier

-Message d'origine-
I am facing lots of problems in formatting xsl's

as we have frontpage for generating html code , emulators for generating wml
code,

do we have any tool for creating xsl's for html , wap  which is easy to use
, placing components and getting xsl code 
instead of writing and checking it again and again

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Rant (was: Re: Style-free XSLT Style Sheets samples code)

2001-06-15 Thread JEULIN Olivier

> On Fri, 15 Jun 2001, Daniel Schneider wrote:
> 
> > . and IE users can't see the *.text as intended. This 
> is one very simple
> > reason why I really do not recommend IE in any educational 
> environment.
> 
> Even worse with Cocoon-generated XML ==> HTML files. Say you 
> have foo.xml
> and transform it with Cocoon and XSLT to an HTML file. You cannot view
> source with IE, because it insists on wanting to show the original XML
> file instead of the generated HTML. Of course it can't get at 
> the original
> XML and so comes up with an error message to that effect.

Well, I'm using IE 5.0 (NT) and I can display the HTML code...
But I haven't succesfully installed the MS's xml parser and stuff...
This bug appears to be another "functionality" of XML support by IE :-/

Olivier

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Why is Cocoon returning the XML and not adding in my XSL??? !

2001-06-14 Thread JEULIN Olivier

Could you please describe which operations your performing and how/where you
call the XSLT processor ?

> -Message d'origine-
> De : Tim Darling [mailto:[EMAIL PROTECTED]]
> Envoyé : jeudi 14 juin 2001 00:06
> 
> It returns:
>  "http://www.w3.org/TR/WD-html-in-xml/DTD/xhtml1-strict.dtd";>
> 
> 
> 
> Vase and Stones
>  
> 
> 
> 
> The stylesheet is there.. Anyone know?  Thanks

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Formating !

2001-06-12 Thread JEULIN Olivier

Hi,
WARNING: you are using a deprecated taglib! The correct one is esql, not
sql.
Take a look at your cocoon/samples/sql for a sample.
You will find the available elements in esql.xsd in the same directory.
Olivier

> -Message d'origine-
> De : Gustavo Mejia [mailto:[EMAIL PROTECTED]]
> Envoyé : lundi 11 juin 2001 20:29
> À : [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Objet : Formating !
> Importance : Haute
> 
> 
> > Hi,
> >
> > I am new using cocoon, I am get results using a query, and 
> now I wan format that information, could you
> > tell how can I do that ? I know that I need XSL document, I 
> already try with this, and I did't get it.
> > here my code ..
> >
> > 
> > 
> >
> >  >   language="java"
> >   xmlns:sql="http://www.apache.org/1999/SQL";
> >   xmlns:xsp="http://www.apache.org/1999/XSP/Core";
> >   xmlns:request="http://www.apache.org/1999/XSP/Request";
> > >
> >
> >   
> >
> >   
> > oracle.jdbc.driver.OracleDriver
> > jdbc:oracle:thin:@host:1521:CTA
> > mypassword
> > myuser
> >empleados
> >registro
> >
> > select * from employee order by empno
> >  
> >   
> > 
> >
> >  Thanks in advance !
> >  Gustavo Mejia
> >  www.Infotec.com.mx
> 
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: Netscape can't define the tag

2001-06-11 Thread JEULIN Olivier

Hi,
try to generate a 'cocoon-format' processing instruction for 'text/html'
(see any sample from cocoon).
This is strange anyway, because even without this line, cocoon HTMLize my
pages well ( -> , etc.). I'm using mosilla 0.9 and netscape 4.75
under linux
OJ

> -Message d'origine-
> De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Envoyé : lundi 11 juin 2001 23:45
> À : [EMAIL PROTECTED]
> Objet : Netscape can't define the  tag
> 
> 
> hi,
> 
> I try to generate html file from xml and xsl by using xalan. 
> The html generated is running well 
> with IE, but Netscape can't define the  tag. May i know 
> how to solve the problem ?
> 
> 
> from 
> Kok Choon.
> 
> 
> E-mail: [EMAIL PROTECTED]
> Date: 06/12/01
> Time: 05:44:42
> 
> This message was sent by Z-Mail Pro - from NetManage
> NetManage - delivers Standards Based IntraNet Solutions
> 
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: element and xinclude

2001-06-06 Thread JEULIN Olivier

Bonsoir JC :)
I have asked the same question as (many!) others before
(it's all in the list archives... shame on us :) )
you *must* use an 'include' element for xinclude to work:

...

-Message d'origine-
I would like to include the content of a file into my xsp 
page.
So I think I need to use this : (to generate the xinclude 
dynamicaly)

file
xml


But it's not work : I've got the "whatever" tag in my xml 
flow result but nothing from my file.
Thanks for your help
JC

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: ESQL and Access

2001-05-31 Thread JEULIN Olivier

Hi Dino,
I think there is no JDBC driver for Access, so you'll have to use a generic
ODBC driver.

I guess such subject has been discussed, please take a look at a mail list
archive (they are 
referenced in http://xml.apache.org/cocoon/mail-archives.html; I suggest
'RealTime - U',
search in it with google: use keywords like "site:mailman.real-time.com
cocoon-users access database")

Good luck (you could also consider mooving the DB from Access to another
server, their are a couple free converting tools available :) )

Olivier
-Message d'origine-
Hi, I'm Dino Fratelli, an italian student. I would to know if it is possible
to connect, trough xml and esql, to a MS Access database. I found the
correct string to connect to PostgreSQL and MySQL but don't to Access.

I need your help!

Thanks in advance, Dino.

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: HTML in XML Content

2001-05-30 Thread JEULIN Olivier

If you content is a XML well-formed document, try using the 'esql' taglib
and the 'esql:get-xml' tag to get the column value (see
'samples/sql/esql.xsd' in cocoon's directory for a complete list of
available tags, and the sample in the same directory)

Olivier

-Message d'origine-
My problem is like this:
We have a dB with our content in, the content have some styling tags in like
 etc.

I would like to know if it is possible for cocoon to serve the data with
trying to interpret the html tags.
(...)

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




RE: How to remove the last line added by cocoon

2001-05-30 Thread JEULIN Olivier

change the 'verbosity' variable to 'false' in your 'cocoon.properties' file
(at the end of the file; and restart cocoon!)

-Message d'origine-
Hi there
Anybody knows how to skip the last line added by cocoon like this
""
Thanks for your precious time
Sudhir

-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




[C1] xinclude tags not processed if called inside a taglib (3 steps approach)

2001-05-29 Thread JEULIN Olivier

Hello,
I'm trying to use a custom taglib to include (parts of) xml files.
My goal is to achieve a complete separation between xml sources, xsp which
merge them, and further XSLT/XSL processing. I would also like to have all
"cocoon-process" instructions grouped in the xsp file.

If I uncomment my tag "toto:title" and the call to xsp and its stylesheet,
xinclude instructions work fine.
But, if I put them back, xinclude instuctions are left as is (but Xinclude
seems to be call, as it inserts a comment: "processed by XInclude" !?). (see
attached html files)

I have tried to insert  dynamicaly in the
xsp:page template: it doesn't work either.

What's the correct way to do it ?

(Im using cocoon 1.8.2 and tomcat 3.2.1-1)

Here are my 3 files:

## index.xml ##











http://www.w3.org/1999/XML/xinclude";
  xmlns:xsp="http://www.apache.org/1999/XSP/Core";
  xmlns:toto="http://localhost/toto";>
  
  


  

  
  

  


  



 logic.xsl ###


http://www.w3.org/1999/XSL/Transform";
   xmlns:xsp="http://www.apache.org/1999/XSP/Core";
   xmlns:xinclude="http://www.w3.org/1999/XML/xinclude";
   xmlns:toto="http://localhost/toto";>


 
  
  
 
 


  

  



  

  




## pages.xsl #


http://www.w3.org/1999/XSL/Transform";>



  
  
  




  TITLE []



  MENU
  



  CONTENT
  



  FOOTER



  

  






  
  TITLE []


  

  
  

  


  FOOTER




  



  
MENU
titi

  
  
CONTENT
 sdfkjsh dfsdfksjfh skdlfjs dflksjf hsd.
 sdf
  
  


  FOOTER





-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>