Long Articles

7 posts by 3 authors in: Forums > CMS Builder
Last Post: February 14, 2012   (RSS)

By Toledoh - February 7, 2012

Hi All,

Just after some pointers...

I've a client that is producing reports, typically about 14 pages or so, with text, charts, references etc.

Rather than produce them in Word, or even InDesign etc, I'm thinking of publishing them direct to web via CMSB. Then, print version via the PDF plugin.

Has anyone done much of this? If so, have you got it looking professional? how do you handle pagination (automatically at heading levels?)

Would love your thoughts.
Cheers,

Tim (toledoh.com.au)

Re: [Toledoh] Long Articles

By Jason - February 8, 2012

Hi Tim,

One way to approach this would be to have each page be a separate record. This would make pagination easy to deal with. The PDF print version could be a page that just ouputs each record of the report.

Of course, the simpliest solution would be to have the report created as a PDF using another program, and then uploaded to CMS Builder to publish it on the web.

Hope this helps
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

Re: [Jason] Long Articles

By Toledoh - February 8, 2012

Thanks Jason,

I was thinking, wouldn't there be some way of putting in a something like "***page-break*** that could then be replaced by an if statement that converted it to either tabs, or some kind of pagination?

Just thinking...
Cheers,

Tim (toledoh.com.au)

Re: [gkornbluth] Long Articles

By Toledoh - February 9, 2012

Thanks Jerry,

I think I'm going to try to work through a system using jquery tabs... I'll let you know how I progress.
Cheers,

Tim (toledoh.com.au)

Re: [Jason] Long Articles

By Toledoh - February 9, 2012 - edited: February 9, 2012

Can someone help me with "placeholders" for this?

I want to enter something like **break-tab1** in the WYSIWYG, and then use something like

<?php echo str_replace('**break',......

to get
<span class="tab1">tab1</span>

Any ideas?
Cheers,

Tim (toledoh.com.au)

Re: [Toledoh] Long Articles

By Jason - February 14, 2012

Hi Tim,

If you know how many tabs you need you could try something like this:

Example:

<?php

$content = $record['content'];

foreach (range(1, 5) as $tab) {
$placeHolder = "**break-tab$tab**";
$tabHTML = "<span class = \"tab$tab\">tab$tab</span>";

$content = str_replace($placeHolder, $tabHTML, $content);
}

?>

<?php echo $content; ?>


This would work for tabs 1 - 5

Hope this helps
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/