On Fri, 10 Sep 2004 06:55:04 +0900, Mark Probert wrote

> I have a LeftNav panel that includes
> 
>     def foo_page
>         '/foo'     # mapfile.conf -->  /foo: Run::Foo
>     end
> 
> 'foo' includes the LeftNav and the header.  However, I am not sure 
> of how to pass @user via the LeftNav.  If I change LeftNav to:
> 
>     def foo_page
>         newPage = page_named("Run::Foo")
>         newPage.user = @user
>         yield newPage
>     end
> 
> I get an error
> 
>   <a href="
>   no block given
>   (eval):39:in `credit_page'
> 
> Any ideas on how to pass the @user to the LeftNav?

Yeah.  You can see an example of this in the webrick demo.  However, your 
snippet of code up there is exactly what you want.

foo_page() should create the new page, assign @user to it, and then yield 
it, exactly as you are doing.

The change you need to make is in your HTML:

Instead of this:

Goto foo

you want this:

<a oid="foo_page">Goto Foo</a>



Make sense?


Kirk Haines