View Issue Details

This issue affects 1 person(s).
 2
IDProjectCategoryView StatusLast Update
12425Bug reportspublic2026-11-19 22:23
Reportertpartner Assigned To 
PrioritynoneSeverityminor 
Status closedResolutionfixed 
Product Version3.x 
Summary12425: Need to define path to template directory in <filename> tags of config.xml
Description

When extending a template, in the "replace" attributes of the <filename> tags, we need to insert the relative path from the /templates directory to the upload/templates/templateName/ directory - see attached screenshot and lines 32, 35 and 44 of the attached config.xml.txt.

Is there a way to have that path automatically detected if the config file is in a custom template (in upload/templates/)?

TagsNo tags attached.
Attached Files
capture-2.png (24,504 bytes)   
capture-2.png (24,504 bytes)   
config.xml.txt (2,172 bytes)   
<?xml version="1.0" encoding="UTF-8"?>
<!--
    Default configuration for the template.
    In future versions of LimeSurvey, it will be used to fill a template table,
    and to give user control on template configuration (like variables to use to render the questions, banners, background, etc.)
-->

<config>
    <!-- Those metadata will be displayed in the template configuration page. They are not used for now. -->
    <metadatas>
        <name>Default Extended 1</name>
        <extends>default</extends>
        <creationDate>19/05/2017</creationDate>
        <author>Louis-Sébastien Gac Artigas</author>
        <authorEmail>louis.gac@limesurvey.org</authorEmail>
        <authorUrl>http://www.limesurvey.org</authorUrl>
        <copyright>Copyright (C) 2005 - 2016 LimeSurvey Gmbh, Inc. All rights reserved.</copyright>
        <license>GNU General Public License version 2 or later</license>
        <version>2.0</version>
        <apiVersion>3</apiVersion>
        <description>A custom extension of the Default LimeSurvey Template.</description>
        <last_update>2017-05-24 00:00:04</last_update>
    </metadatas>


    <!--
        Here the list of the css/js files to load.
        Any file here will be loaded via the asset manager (when in config.php debug = 0)
    -->
    <files>
        <css>
            <filename replace="../upload/templates/default_extended_1/css/template.css">css/template.css</filename>
        </css>
        <js>
            <filename replace="../upload/templates/default_extended_1/scripts/template.js">scripts/template.js</filename>
        </js>
    </files>

    <!-- Here datas about how LimeSurvey should load the template -->
    <engine>
        <!-- If empty, bootstrap css/js files will not be loaded. In the future, we may have more engines, like foundation -->
        <cssframework>
            <name>bootstrap</name>
            <css replace="../upload/templates/default_extended_1/css/bootstrap.css">css/bootstrap.css</css>
        </cssframework>

        <!-- Path of the twig files -->
        <viewdirectory>views</viewdirectory>
    </engine>
</config>
config.xml.txt (2,172 bytes)   
Bug heat2
Complete LimeSurvey version number (& build)
I will donate to the project if issue is resolved
Browser
Database type & version
Server OS (if known)
Webserver software & version (if known)
PHP Version
Git branch / Pull Request URL

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2026-11-19 22:23

administrator   ~87730

In LimeSurvey 7 file entries in a theme's config.xml are relative to the theme itself (e.g. css/custom.css) and are resolved automatically through theme inheritance, so no path to the upload directory is needed. Closing as done.

Issue History

Date Modified Username Field Change
2017-05-24 16:41 tpartner New Issue
2017-05-24 16:41 tpartner Status new => assigned
2017-05-24 16:41 tpartner Assigned To => LouisGac
2017-05-24 16:41 tpartner File Added: capture-2.png
2017-05-24 16:41 tpartner File Added: config.xml.txt
2022-07-28 16:05 DenisChenu Assigned To LouisGac =>
2022-07-28 16:05 DenisChenu Status assigned => new
2026-11-19 22:23 c_schmitz Note Added: 87730
2026-11-19 22:23 c_schmitz Bug heat 0 => 2
2026-11-19 22:23 c_schmitz Status new => closed
2026-11-19 22:23 c_schmitz Resolution open => fixed
2026-11-20 10:33 c_schmitz Category Templates => (No Category)