[Koha] some documentation (19.11 and 20.05) pages are slightly outdated
Quỳnh Vũ Đỗ
quynhvd at thanglong.edu.vn
Thu Sep 17 18:05:20 NZST 2020
Hello
I have been using Koha documentation to extend Koha 19.11 as a CMS and
followed instructions given on the following page:
https://koha-community.org/manual/19.11/en/html/extending_koha.html#using-koha-as-a-content-management-system-cms
*Under the section "Editing the pages template" it is written as follows:*
- Copy /usr/share/koha/opac/htdocs/opac-tmpl/bootstrap/en/modules/
opac-main.tt to /usr/share/koha/opac/htdocs/opac-tmpl/bootstrap/en/modules/
pages.tt
- Edit /usr/share/koha/opac/htdocs/opac-tmpl/bootstrap/en/modules/pages.tt
- At approximately line 61, change this:
[% IF ( OpacMainUserBlock ) %]<div id="opacmainuserblock">[%
OpacMainUserBlock %]</div>[% END %]
- To this:
[% IF ( page_test ) %]<div id="opacmainuserblock">[% page_test %]</div>[%
END %]
*But in the pages.tt <http://pages.tt> file (copied from opac-main.tt
<http://opac-main.tt>) and where modifications are to be carried out, the
line shows not at approximately line 61 but at line 152 and is written as:*
[% IF ( OpacMainUserBlock ) %]<div id="opacmainuserblock">[%
OpacMainUserBlock | $raw %]</div>[% END %]
It is of course a very minor difference but for the sake of exactitude, it
would be nice to have these differences corrected (line number and code)
*There is however a bigger issue with the following content:*
Remark: You may wish to disable your News block of these CMS style pages
e.g. when you do not want it displayed on the CMS style pages or where the
News block is long enough that it actually makes the ‘page_test’ include
scroll outside the default viewport dimensions. In that case, remove the
following code from your pages.tt template.
[% IF ( koha_news_count ) %]
<div id="news">
<table class="table table-bordered">
[% FOREACH koha_new IN koha_news %]
<thead><tr><th>[% koha_new.title %]</th></tr></thead>
<tbody><tr><td><p>[% koha_new.new %]</p>
<p class="newsfooter"><i>(published on [% koha_new.newdate
%])</i></p></td></tr></tbody>
[% END %]
</table>
</div>
[% END %]
*Because the code to be researched as above has been completely modified
and spans from line 72 to 102 (30 lines of code) and even further.*
The same remarks stand also for 20.05 documentation (
https://koha-community.org/manual/20.05/en/html/extending_koha.html#using-koha-as-a-content-management-system-cms
)
To whom shall we report this, else than in this mailing list?
Kind regards
Quynh
=================
M. Vũ Đỗ Quỳnh (Ph.D)
Trường Đại học Thăng Long - Université de Thang Long - Thang Long
University (Hanoi, Vietnam)
Phó Hiệu Trưởng, phụ trách HTQT - Vice-recteur chargé de la coopération
internationale - Vice-Rector in charge of International Cooperation
Web: http://thanglong.edu.vn/
More information about the Koha
mailing list