Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Adding a url via href-tag to the footer of a survey theme does not work

  • CMcFly
  • CMcFly's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
3 years 6 months ago #221545 by CMcFly
Hello,

I need to add a URL to a privacy document (in html) to the footer of survey themes as well as to the admin footer.

I found out how to add a line oft html to the footer of the survey in the theme editor. But I can't get the URL work. LimeSurvey adds the filename of the privacy document to the index.php path:
Code:
https://umfrage.libell-e.de/index.php/Datenschutz-limesurvey.html
.

In the editor I entered 
Code:
<a href="./Datenschutz-limesurvey.html">Datenschutz</a>
. The document is stored in the root folder ( umfrage.libell-e.de/Datenschutz-limesurvey.html ).

What am I doing wrong?

And: How do I get the URL into the footer of the admin pages?

Any help would be appreceated.

Regards, Christoph
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
3 years 6 months ago #221566 by tpartner
1) Use the absolute URL.

2) Custom admin theme - www.limesurvey.org/manual/Custom_Admin_Themes

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • CMcFly
  • CMcFly's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
3 years 6 months ago #221568 by CMcFly
Thanks, Tony. Now the href-tag does what I want to be done.

2) I found this part of the manual yesterday. But the admin themes only contain css files, images and the config.xml. But I need to add a line of html with link to the privacy disclaimer into the footer.
The topic has been locked.
  • CMcFly
  • CMcFly's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
3 years 6 months ago #221571 by CMcFly
Found it!

The footer is in /application/views/admin/super.

I know that I change it on my own risk. But the european GDPR says a privacy policy is mandatory and has to be only one click away.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
3 years 6 months ago #221580 by tpartner

I know that I change it on my own risk.

You could insert it with a little JS in a custom.js file - www.limesurvey.org/manual/Custom_Admin_T...nto_a_custom_theme_2

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: CMcFly
The topic has been locked.
  • CMcFly
  • CMcFly's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
3 years 6 months ago #221584 by CMcFly
Thanks again, Tony. JS did it.

It has taken a while, because I am not very familiar with js, but now it works. Just to illustrate the code I used for someone who has the same problem:
Code:
$(document).on('ready pjax:scriptcomplete',function(){
    /**
     * Code included inside this will only run once the page Document Object Model (DOM) is ready for JavaScript code to execute
     * @see https://learn.jquery.com/using-jquery-core/document-ready/
     */
      //Insert a custom footer message
     $('<div class="container-fluid"><div class="row"><div  class="col-xs-12 text-center"><p style="position: relative;bottom:0;font-size:18px !important;font-weight:400 !important;">Place your footer text here</p></div></div></div>').insertBefore('div[id^="bottom"]');
});
The first line and the following comment are from a custom.js file in the vanilla template.

Regards, Christoph
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose