You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Brian May <ba...@snoopy.apana.org.au> on 2000/08/03 01:28:36 UTC

Re: [Cocoon Devel]XSL/XSP

Hello All,

I have a similar problem with the following XSP code:

[...]
<result id="gb-addentry">

  <xsp:logic>
       String name=request.getParameter("name");
  [...]
  </xsp:logic>

</result>
[...]

>>>>> "Ricardo" == Ricardo Rocha <ri...@apache.org> writes:

    Ricardo> The "request" object is accessible _only_ inside the
    Ricardo> "populateDocument" method (i.e. inside the user root
    Ricardo> element). It's _not_ accessible inside the class-level
    Ricardo> section (i.e., <xsp:logic> right beneath the root
    Ricardo> <xsp:element>).

How do you get stuff into the populateDocument method? I can't see
that method in the output Java code. Instead, everything is in the
"generate" method. The variable "request" is not defined anywhere.


>>>>> "Donald" == Donald Ball <ba...@webslingerZ.com> writes:

    Donald> the statement needs to appear underneath your root
    Donald> element:

    Donald> <xsp:page> <xsp:logic> static private int counter = 0;
    Donald> </xsp:logic> <page> <xsp:logic> String id =
    Donald> request.getParameter("id"); </xsp:logic> </page>
    Donald> </xsp:page>

Its my impression I do this correctly. ie <result ...> is my root
element.

-- 
Brian May <ba...@snoopy.apana.org.au>

Re: [Cocoon Devel]XSL/XSP

Posted by Donald Ball <ba...@webslingerZ.com>.
On 3 Aug 2000, Brian May wrote:

> >>>>> "Donald" == Donald Ball <ba...@webslingerZ.com> writes:
> 
>     Donald> are you using cocoon2? if not, your namespace declarations
>     Donald> are wrong. if so, i'm afraid i will have to defer to
>     Donald> ricardo or another cocoon2 expert - i've had sadly little
>     Donald> time to play with cocoon2 since pier's initial
>     Donald> implementation many months ago.
> 
> Yes. I am using cocoon2. I thought this thread was cocoon2, on double
> checking, I see I was probably mistaken. Oops. Sorry for any
> confusion.

well, as far as i can tell, your page should still work fine. you might
examine the generated java page to see where it looks malformed and use
that as a starting point.

- donald


Re: [Cocoon Devel]XSL/XSP

Posted by Brian May <ba...@snoopy.apana.org.au>.
>>>>> "Donald" == Donald Ball <ba...@webslingerZ.com> writes:

    Donald> are you using cocoon2? if not, your namespace declarations
    Donald> are wrong. if so, i'm afraid i will have to defer to
    Donald> ricardo or another cocoon2 expert - i've had sadly little
    Donald> time to play with cocoon2 since pier's initial
    Donald> implementation many months ago.

Yes. I am using cocoon2. I thought this thread was cocoon2, on double
checking, I see I was probably mistaken. Oops. Sorry for any
confusion.
-- 
Brian May <ba...@snoopy.apana.org.au>

Re: XSL/XSP

Posted by Donald Ball <ba...@webslingerZ.com>.
On 3 Aug 2000, Brian May wrote:

> >>>>> "Donald" == Donald Ball <ba...@webslingerZ.com> writes:
> 
>     Donald> post the whole page - i reckon the problem is in one of
>     Donald> the [...] areas.
> 
> Ok, you asked for it ;-)
> 
> Seriously: normally my code looks better then this, however, this is
> the best I could do with my current knowledge of XSP. Any hints on how
> to improve it would be appreciated... I can't help but think that this
> code is *much* more complicated then it needs to be. If you need
> help trying to work out how it is meant to work, just ask.
> 
> This use to work (believe it or not) 1st-July.

are you using cocoon2? if not, your namespace declarations are wrong. if
so, i'm afraid i will have to defer to ricardo or another cocoon2 expert -
i've had sadly little time to play with cocoon2 since pier's initial
implementation many months ago.

- donald


Re: XSL/XSP

Posted by Brian May <ba...@snoopy.apana.org.au>.
>>>>> "Donald" == Donald Ball <ba...@webslingerZ.com> writes:

    Donald> post the whole page - i reckon the problem is in one of
    Donald> the [...] areas.

Ok, you asked for it ;-)

Seriously: normally my code looks better then this, however, this is
the best I could do with my current knowledge of XSP. Any hints on how
to improve it would be appreciated... I can't help but think that this
code is *much* more complicated then it needs to be. If you need
help trying to work out how it is meant to work, just ask.

This use to work (believe it or not) 1st-July.


Re: [Cocoon Devel]XSL/XSP

Posted by Donald Ball <ba...@webslingerZ.com>.
On 3 Aug 2000, Brian May wrote:

> Hello All,
> 
> I have a similar problem with the following XSP code:
> 
> [...]
> <result id="gb-addentry">
> 
>   <xsp:logic>
>        String name=request.getParameter("name");
>   [...]
>   </xsp:logic>
> 
> </result>
> [...]

post the whole page - i reckon the problem is in one of the [...] areas.

- donald