Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Does Interwoven support pagination?
LeslieShen
How to implement pagination in Interwoven? Just like a search result page with pervious page and next page button. How to create a page like google search result page by using DCR, DCT, TPL?
I appreciate if give me an example.
Find more posts tagged with
Comments
gzevin
I would suggest that you try to rephrase your question, as it's not completely clear what do you really want. As a generic answer - yes, you can create multiple pages DCTs, and using your TPLs you can generate a number of files.
Greg Zevin, Ph.D. Comp. Sc.
Independent Interwoven Consultant/Architect
Sydney, AU
Adam Stoller
Are you talking a dynamic number of pages being returned as a result of some query that an end-user performs on your web site -- or are you talking about a static number of pages being generated from a DCR via a PT?
The former is a web-appliction and the responsibility would be in the coding of the webapp.
The latter can be achieved if you have some logic (either built into the DCT/DCR or something convoluted [IMO] in your PT) that determines what amount of content should get placed on a page of output. The PT would need to be responsible for determining how many pages will be generated and what the names of those pages will be, and then it is responsible for generating all those pages -- while doing so, it would create a unique footer (or header) on each page with page number/reference links to the other pages being generated. The PT could use either basic Perl I/O or Templating's iw_ostream to create the multiple pages (the initial page name would be specified on the command line to iwgen or iwpt_compile.ipl) - and you would probably want to make sure that all the *other* pages have the correct TST EAs associated with them so that the pages created are treated as generated pages within the TS GUI (i.e., if someone tried to edit a generated page it takes them, instead, to editing the DCR from whence that page was generated).
I won't say it's "trivial" - but it's not exactly "rocket science" either - the most important part would be to do some serious design/planning before attempting to implement; think the entire process through and figure out how to accomplish each of the building blocks of the design so that it becomes relatively simple to put all the pieces together and arrive at a solution.
My customer's system was set up this way such that the DCT has a replicant which allows you to specify whether any given paragraph of content should be followed by a new page - the PT processes the DCR to get a count of the new pages specified within (which lets it know how to generate the footer with the page number/reference links) and then after generating the initial page (as specified on the command line - e.g. "/..../mycontent.html") names each page with a suffix based upon that initial page's name (e.g., "/..../mycontent_pg2.html, /..../mycontent_pg3.html, etc.). The logic for generating the footer determings which page number/references are links, and which one [the current page] is just text.
I'd suggest you try to work out most (if not all) of the actual implementation code yourself - since it will make it easier for you to develop it to your requirements and significantly easier for you to maintain it over time - whereas a spoon-fed solution where someone here gives you code will (a) be implemented according to what *they* think of as requirements - as opposed to *your* requirements; and (b) will leave you in as much trouble, if not more, when it comes time for you to make changes / debug issues -- and there will be changes; that's the nature of the business.
Once you have flushed out your design and started doing the implementation - if you have *specific* questions regarding a *particular* piece of code you're trying to develop - that's where these forums can be a lot of help - in tackling a specific, focused piece of the overall implementation.
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
LeslieShen
Thank u for giving me such useful guide. Yes, what I wanna implement is the second situation. But, frankly speaking, I am an interwoven rookie and lack enough support of interwoven. i.e. The only way I know what does iw_ostream mean is by searching this forum, because I am unable to get the interwoven manual. So maybe the pagination task is too hard for me.
Anyway, thank you.
gzevin
if you have an access toa teamsiote server, the templating docs are on <server>/iw/help/tst/pt
also, if you need the docs, I can mail you a pdf...
LeslieShen
Wow, that will be very helpful. Thank u, gzevin. My Email address is
les.shen@gmail.com
I really need some pdf docs about <iw_****> tag and perl related.
Thank you again.
gzevin
I will mail you the file, however do look at the docs on the server. they are up-to-date and comprehensive
Greg Zevin, Ph.D. Comp. Sc.
Independent Interwoven Consultant/Architect
Sydney, AU
LeslieShen
Got it, thank you.