Im sorry, I don't think I explained that well at all (I was barely awake
at the time). What I need is along the lines of a dynamic include in a
JSP. Where the included JSP still executes as always but you are able to
specify the include path itself as a variable. That's what I'm looking to
accomplish. If this can be done with Block and RenderBlock, can you
provide more details? Thanks!

Michael


-----Original Message-----
From: "Firas Adiler" <[EMAIL PROTECTED]>
Sent: Thu, September 21, 2006 12:25 pm
To: "Tapestry users" <users@tapestry.apache.org>
Subject: RE: Dynamic Sections on a Page

Hi,

I think these components are well suited for this kind of job:

http://tapestry.apache.org/tapestry4/tapestry/ComponentReference/RenderBlock
.html
http://tapestry.apache.org/tapestry4/tapestry/ComponentReference/Block.html


</Firas>


-----Original Message-----
From: Mike Grundvig [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 21, 2006 3:41 PM
To: Tapestry users
Subject: Dynamic Sections on a Page

Hi all; first off, I just wanted to express my thanks to the devs and
community for making Tapestry. It's a real piece of art. Thanks!

I'm working on a site that has an admin system to store advertisments. These
advertisements are small HTML blocks that they want inserted into specific
places inside of a page. The entire site is broken into sections and the ads
are tied to all the pages in a section. I know I can make a custom component
and inject my ad service into it and then use that to load the files from
the file system and dump the ad HTML right into the pages but that feels
very clumsy. I want the ad HTML to be valid tapestry pages in their own
right so they can take advantage of all the capabilities of tapestry.

Basically, Id like a component that looks something like this:

<span jwcid="@AdDisplay" adId="1" sectionId="learn">Ad 1 goes here</span>

And that would go on every page with a different section id for all
locations. Then it would do this internally (psuedo code, obviously):

// the url for this ad might be "/ads/blah.html" (yes, I have friendly urls
working)
Template template = getAdService().getTemplate(adId, sectionId);
template.render();

How can I get a page from the tapestry engine via the name or path or some
such in a way that I can dump it into the page? Thanks in advance for any
advice!

Michael




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




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

Reply via email to