Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: Set a default survey, skip Survey List page

Set a default survey, skip Survey List page 1 year 4 months ago #93727

  • jonsen
  • jonsen's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 71
  • Thank you received: 6
  • Karma: 1
Dear limesurvey community,

I would like to skip the Survey List page and forward directly to a default survey. Hardcoding the GET variable in the index.php led to faulty behaviour (solved in another thread). What is the correct way to do it?

What I don't get: Why is the Survey List even diplayed at all when there is only one survey?

Best
Jonsen
The administrator has disabled public write access.

Set a default survey, skip Survey List page 1 year 4 months ago #93735

  • jonsen
  • jonsen's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 71
  • Thank you received: 6
  • Karma: 1
holch wrote:
to skip the welcome page LS has an option in the interface now, as far as I recall. And the redirect I would make with .htaccess.

Thank you. I will wait for other posts, but probably it will be a .htaccess-based solution. The option in the interface is in v2.0? This survey is my last one on 1.92+...
Last Edit: 1 year 4 months ago by jonsen.
The administrator has disabled public write access.

Set a default survey, skip Survey List page 1 year 4 months ago #93737

  • holch
  • holch's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 2549
  • Thank you received: 285
  • Karma: 102
I think this was also available in 1.92, but I am not 100%. I'll start localhost and check in 2.0 where to find. But if it is there, I am quite sure that it exists quite a while (pre 2.0).
Have a look at the manual! It is a really valuable source for information. Here some helpful links:
Manual (EN) | Question Types | Question Attributes | Workarounds

If you found this answer helpful and it saved you some time please consider a donation to the project to keep Limesurvey going!
The administrator has disabled public write access.

Set a default survey, skip Survey List page 1 year 4 months ago #93738

  • holch
  • holch's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 2549
  • Thank you received: 285
  • Karma: 102
Somehow my local webserver won't start...

But here, this should clarify:
docs.limesurvey.org/Workarounds%3A+Manip...ing_the_welcome_page

This option is availabe since 1.91, so quite a while now.
Have a look at the manual! It is a really valuable source for information. Here some helpful links:
Manual (EN) | Question Types | Question Attributes | Workarounds

If you found this answer helpful and it saved you some time please consider a donation to the project to keep Limesurvey going!
The administrator has disabled public write access.
The following user(s) said Thank You: jonsen

Set a default survey, skip Survey List page 1 year 4 months ago #93740

  • jonsen
  • jonsen's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 71
  • Thank you received: 6
  • Karma: 1
Thank you for your help holch!

But that option is only available for the "welcome" page within a survey, not for the "survey list" page which is shown when lime is called without a survey id in the URL.

As the "survey list" doesn't have a "submit" button, the Javascript/jQuery-Approach in the workaround section can't be adapted for this.

I will try the .htaccess approach now and post my results here.

Best
Jonsen
The administrator has disabled public write access.

Set a default survey, skip Survey List page 1 year 4 months ago #93741

  • holch
  • holch's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 2549
  • Thank you received: 285
  • Karma: 102
Well, when you said that you went directly to the survey, skipping the welcome page, I assumed that you talk about the welcome page in the survey and not about the survey list page.

I thought you would be redirecting from the survey list page to the survey and then skip the welcome page of the survey, while in reality you only wanted to redirect fromt he survey list page to the actual survey.

so the problem is actually a lot easier. This is definitely a job for .htaccess.
Have a look at the manual! It is a really valuable source for information. Here some helpful links:
Manual (EN) | Question Types | Question Attributes | Workarounds

If you found this answer helpful and it saved you some time please consider a donation to the project to keep Limesurvey going!
The administrator has disabled public write access.

Set a default survey, skip Survey List page 1 year 4 months ago #93742

  • jonsen
  • jonsen's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 71
  • Thank you received: 6
  • Karma: 1
holch wrote:
Well, when you said that you went directly to the survey, skipping the welcome page, I assumed that you talk about the welcome page in the survey and not about the survey list page.

Yes, sorry, i misused the "welcome page" term in the other thread...

L8or
The administrator has disabled public write access.

Set a default survey, skip Survey List page 1 year 4 months ago #93794

  • DenisChenu
  • DenisChenu's Avatar
  • OFFLINE
  • Moderator Lime
  • Posts: 6192
  • Thank you received: 786
  • Karma: 238
Hello,

Can be an idea for "Plugin system" : www.limesurvey.org/fr/forum/news/92759-y...s-for-limesurvey-205

But you can do it in javascript,
- Set the defult template in General settings to your own template
- Edit surveylist.pstpl and replace with:
<script type="text/javascript">
<!--
window.location.replace("http://example.com/index.php/XXXXXX");
//-->
</script>
<noscript><a href="http://example.com/index.php/XXXXXX">Go to the survey</a></noscript>
example.com/index.php/XXXXXX add to becopy/pasted from Survey URL in LS admin.

Denis
The administrator has disabled public write access.
The following user(s) said Thank You: jonsen

Set a default survey, skip Survey List page 1 year 4 months ago #93806

  • jonsen
  • jonsen's Avatar
  • OFFLINE
  • Senior Lime
  • Posts: 71
  • Thank you received: 6
  • Karma: 1
Thank you, Denis, that works very nicely!

For anyone interested, the code for LimeSurvey < v2.0 is a little different, because it doesn't have the fancy URLs, also I added a little more info in <noscript>:
<script type="text/javascript">
	<!--
	window.location.replace("https://example.com/index.php?sid=99184"); 
	//--> 
</script>
<noscript>
	Javascript seems to be deactivated.<br />
	Please allow Javascript for the domain example.com to answer this survey.<br />
	<br />
	<a href="https://example.com/index.php?sid=99184">Click here</a>
	to get to the survey.
</noscript>

Best
Jonsen
Last Edit: 1 year 4 months ago by jonsen.
The administrator has disabled public write access.

Set a default survey, skip Survey List page 1 year 4 months ago #93807

  • DenisChenu
  • DenisChenu's Avatar
  • OFFLINE
  • Moderator Lime
  • Posts: 6192
  • Thank you received: 786
  • Karma: 238
jonsen wrote:
For anyone interested, the code for LimeSurvey < v2.0 is a little different,
example.com/index.php/XXXXXX add to becopy/pasted from Survey URL in LS admin.
;)
You're welcome :-)

If our hints have been helpful and you enjoy limesurvey please consider a donation to give Limesurvey a future .
We do all this in our free time and you don't have to pay a penny for this software.

Without your help we can't keep this project alive.
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Moderators: ITEd
Time to create page: 0.162 seconds
Donation Image