Welcome to the LimeSurvey Community Forum

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

Custom "survey is not active" page?

  • Winocll_48635
  • Winocll_48635's Avatar Topic Author
  • Offline
  • Banned
  • Banned
More
7 years 3 months ago #146345 by Winocll_48635
Custom "survey is not active" page? was created by Winocll_48635
Some things on LimeSurvey are set to general options that effect all surveys while some are set to options custom to each survey.

It looks like the page that notifies respondents that a "survey is not active" (i.e. when it is no longer accepting respondents) falls under the 'general options' in that it gives a basic statement of "This survey is currently not active" (or something similar) that is shared across all surveys.

Is it possible to make this 'survey is not active' page to be customized for each survey?

For instance, if could be a survey about hamburgers it would bring up a picture of a hamburger and say, "the hamburger survey is no longer active" .... AND ... a survey about hotdogs that would bring up a picture of a hotdog and say, "the hotdog survey is no longer active"
The topic has been locked.
  • tammo
  • tammo's Avatar
  • Offline
  • Official LimeSurvey Partner
  • Official LimeSurvey Partner
More
7 years 3 months ago #146346 by tammo
Replied by tammo on topic Custom "survey is not active" page?
As far as I know this is not possible at the moment. I can see the value of it: please make a feature request at: www.limesurvey.org/community-services/feature-requests

Or maybe DenisChenu has/knows/develops a plugin?

Tammo


Tammo ter Hark at Respondage
For Limesurvey reporting, education and customized themes
respondage.nl
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 3 months ago - 7 years 3 months ago #146356 by tpartner
Replied by tpartner on topic Custom "survey is not active" page?
You could add something like this to template.js (modify "keyWord" for different activation states or languages):

Code:
$(document).ready(function() {
  var keyWord = 'expired';
  if($('#tokenmessage').length > 0 && $('#tokenmessage').text().indexOf(keyWord) !== -1) {
    var newMessage =  '<p style="text-align:center">\
                A custom paragraph...\
              </p>\
              <p style="text-align:center">\
                And, another custom paragraph...\
              </p>';
 
    $('#tokenmessage').html(newMessage);
  }
});

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 7 years 3 months ago by tpartner.
The topic has been locked.
More
7 years 3 months ago #146357 by jelo
Replied by jelo on topic Custom "survey is not active" page?

tammo wrote: As far as I know this is not possible at the moment. I can see the value of it: please make a feature request

With a broader scope in mind (and a few years old):
www.limesurvey.org/forum/future-features...tallation-per-survey
bugs.limesurvey.org/view.php?id=10038

The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The topic has been locked.
  • LouisGac
  • LouisGac's Avatar
  • Visitor
  • Visitor
7 years 3 months ago #146362 by LouisGac
Replied by LouisGac on topic Custom "survey is not active" page?
It's in survey runtime helper:
github.com/LimeSurvey/LimeSurvey/blob/ma...timeHelper.php#L1403

If it's something urgent, I can move that code to a view, so you can overwrite it in your template.
The topic has been locked.
  • tammo
  • tammo's Avatar
  • Offline
  • Official LimeSurvey Partner
  • Official LimeSurvey Partner
More
7 years 3 months ago #146363 by tammo
Replied by tammo on topic Custom "survey is not active" page?
That is dangerous to ask: "if it's something urgent...."....

Requests are always urgent, but are they important?

99u.com/workbook/25721/urgent-vs-important

I would say that this is important, but not urgent. That is my way of getting it higher on the priorities list. But stick to your list! ;-)

Tammo


Tammo ter Hark at Respondage
For Limesurvey reporting, education and customized themes
respondage.nl
The following user(s) said Thank You: DenisChenu
The topic has been locked.
  • LouisGac
  • LouisGac's Avatar
  • Visitor
  • Visitor
7 years 3 months ago #146365 by LouisGac
Replied by LouisGac on topic Custom "survey is not active" page?
I mean it would take me 15 minutes to do.
The topic has been locked.
  • tammo
  • tammo's Avatar
  • Offline
  • Official LimeSurvey Partner
  • Official LimeSurvey Partner
More
7 years 3 months ago #146366 by tammo
Replied by tammo on topic Custom "survey is not active" page?
Well, I'll take the bait. If you can do it that fast: let's make it urgent then..

:-)

Tammo


Tammo ter Hark at Respondage
For Limesurvey reporting, education and customized themes
respondage.nl
The topic has been locked.
  • tammo
  • tammo's Avatar
  • Offline
  • Official LimeSurvey Partner
  • Official LimeSurvey Partner
More
7 years 3 months ago #146367 by tammo
Replied by tammo on topic Custom "survey is not active" page?
BTW: it is always good to have a nice new feature in a new release, it makes upgrading/updating worth the trouble!

Tammo


Tammo ter Hark at Respondage
For Limesurvey reporting, education and customized themes
respondage.nl
The topic has been locked.
  • LouisGac
  • LouisGac's Avatar
  • Visitor
  • Visitor
7 years 3 months ago #146369 by LouisGac
Replied by LouisGac on topic Custom "survey is not active" page?
You're going to have a really nice new feature in LS3. We're moving the template view override to a real question template engine: each question could have their own specific template (selected in Display settings). So, it will be very easy to share zip files containing HTML, JS and CSS for custom question types, and with custom question attributes if needed (basically: any old "workaround" could be distributed as question templates).

Btw, long time I didn't spoke with you: You'll be glad to know that Twig engine is integrated for question views and survey templates. So, instead of using keywords in pstpl files, now you can for exemple do something like: {{ aSurveyInfo.adminemail }}. We need to think about what variables should be available from pstpl files (my bet: $oSurvey, $oQuestionGroup, $oQuestion and $oToken)

I'll do the subtemplating engine in January, should be very easy.
The topic has been locked.
  • tammo
  • tammo's Avatar
  • Offline
  • Official LimeSurvey Partner
  • Official LimeSurvey Partner
More
7 years 3 months ago #146370 by tammo
Replied by tammo on topic Custom "survey is not active" page?
Looking forward to you saying: let's test this!

Tammo


Tammo ter Hark at Respondage
For Limesurvey reporting, education and customized themes
respondage.nl
The topic has been locked.
More
7 years 3 months ago #146382 by PaulWeaver1965
Replied by PaulWeaver1965 on topic Custom "survey is not active" page?
It would be fantastic if this can be made to work.

The only reason I have not offered to do it myself is I am not a programmer.

Thanks.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose