[Pmwiki-users] Print view broken (pmwiki 1.0.7)
John Rankin
john.rankin
Tue Aug 31 19:19:26 CDT 2004
I think I see what's happening. See below for suggested fixes.
The publish script included with wikilog bypasses PmWiki's
print template.
It sets $PageTemplateFmt and $UrlLinkTextFmt to the values
it needs to do its job. This creates 2 problems:
- if $EnablePrint = 1; pmwiki's print script comes along and
over-writes the link format needed to handle endnotes correctly
(Problem A below)
- if the administrator sets $PageTemplateFmt *after* loading
the publish script (loaded from wikilog-config.php), this
overwrites the template needed for the printable and publish
views (Problem B below)
On Tuesday, 31 August 2004 8:25 PM, Alexandre Courbot <Alexandre.Courbot at lifl.fr> wrote:
>> Are you able to send me a link to a non-working version, with
>>
>> $enablediag = 1;
>>
>> And perhaps list your config.php file.
>
>Sure. You can try a non-working version at
>
>http://www.lifl.fr/RD2P/Eng
>
>Just click 'Printable view' and see the external links at the middle of
>the page.
This is Problem A.
The fix is to set $EnablePrint = 0; and...
>
>?action=diag does work too.
>
>My config.php is readable at
>http://www.lifl.fr/RD2P/config.php.txt
>
>> One other thing you could try: comment out everything in config.php
>> *except* the include_once("local/wikilog/wikilog-config.php"); plus
>> your logo, your template and $enablediag = 1;
>>
>> Does the problem still occur?
>
>If I do this, I get a fine printable view... in my non-printable
>template. To get the right template I must set $EnablePrint = 1; also
>and in this case, I get the right template but the links are
>messed up.
This is Problem B.
The fix is to move the following line *above* the line that includes
wikilog-config.php
$PageTemplateFmt = 'pub/skins/rd2p/rd2p.tmpl';
>
>It seems to me that this has something to do with $EnablePrint (why is
>it set to 0 in the Calendar script?)
In order to show links as endnotes, the publish script has to
redefine the url link format. It then has to stop pmwiki from
changing it. As a consequence, pmwiki then doen't set the page
template format to the value in $PrintTemplateFmt, so the publish
script has to do that too.
So it's all because we wanted to list link references as endnotes
at the end of the printed document.
If you make those 2 changes to your config.php, it should solve
the problem. Let me know how you get on.
>
>Thanks for your help!
>Alex.
>--
>Alexandre Courbot
>PhD Student - LIFL/RD2P
>http://www.lifl.fr/~courbot/
>
--
JR
--
John Rankin
More information about the pmwiki-users
mailing list