giterlizzi / dokuwiki-template-bootstrap3

Bootstrap-based template for DokuWiki
https://dokuwiki.org/template:bootstrap3
GNU General Public License v2.0
220 stars 77 forks source link

Iconify.php $doku_inc_dirs Setting #572

Closed armouredking closed 1 year ago

armouredking commented 2 years ago

Is your feature request related to a problem? Please describe. The current setup of the theme uses hardcoded options for various different non-standard deployments. If you have a different non-standard deployment, you need to edit the iconify.php file and include it, which is overwritten on updates. See #468 for past example.

Describe the solution you'd like Ability to specify this value from the administration, so that it is not overwritten and does not need to be an array of hardcoded values.

Describe alternatives you've considered Just editing the hardcoding to include your non-standard deployment, and remembering to update it on an update.

Additional context Nonstandard Environment: SWAG Host (LinuxServer.io) (obviously this will be different depending on how you layout your www folder on the SWAG Docker container)

$doku_inc_dirs = array(
    '/opt/bitnami/dokuwiki',                      # Bitnami (Docker)
    '/usr/share/webapps/dokuwiki',                # Arch Linux
    '/usr/share/dokuwiki',                        # Debian/Ubuntu
    '/app/dokuwiki',                              # LinuxServer.io (Docker)
    '/config/www/dokuwiki',           # LinuxServer SWAG
    realpath(dirname(__FILE__) . '/../../../'),   # Default DokuWiki path
);
giterlizzi commented 1 year ago

Hi, actually is not possible to define the DOKU_INC directory in DokuWiki config but you can specify the DOKU_INC constant in <dokuwiki>/lib/tpl/bootstrap3/doku_inc.php file.

# NOTE Some Linux distributon change the location of DokuWiki core libraries (DOKU_INC)
#
#      Bitnami (Docker)         /opt/bitnami/dokuwiki
#      LinuxServer.io (Docker)  /app/dokuwiki
#      Arch Linux               /usr/share/webapps/dokuwiki
#      Debian/Ubuntu            /usr/share/dokuwiki
#
# NOTE If DokuWiki core libraries (DOKU_INC) is in another location you can
#      create a PHP file in bootstrap3 root directory called "doku_inc.php" with
#      this content:
#
#           <?php define('DOKU_INC', '/path/dokuwiki/');
#
#      (!) This file will be deleted on every upgrade of template