I want users to be redirected to the one survey I have in case they they go to the main URL that hosts my Lime Survey install (e.g. survey.domain.com) in case they don't enter the unique survey URL.
Hi ,
In the surveylist.pstpl file of the default template of your install (the most of the time "default" theme) just set a redirection (meta refresh or javascript) pointing to your survey.
I inserted this at the top of the file, and then at other places throughout the file (file contents below) but no luck. I still get to the page that lists the available surveys.
I think you can't insert a meta tag in the surveylist.pstpl because it should be in the header of the page, which is probably in another file of the template. However, if you include the meta refresh function, in the header of the template, it will redirect on any page of the survey. So this won't work.
How about using .htacces to recirect the base URL to the questionnaire?
What I usually do is install Limesurvey in a sub directory of the Domain anyway. Then you could create a index.html in the route document and display the survey directly in an iframe.
Help us to help you!
Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.
But i think you can try to use your own controller for this too.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. -
Professional support
-
Plugins, theme and development
. I don't answer to private message.
Hi Holch,
Using meta-refresh inside the body element is of course invalid for HTML4.01… but actually the trick do the job even with a javaScript-incapable browser. Obviously for a webpage requiring javascript, it's better to use some js redirection.
Thanks Ben! I didn't test it. I just guessed that this could be the problem, as the surveylist file obviously doesn't contain the head tag. But good to know that it would/should work anyway. But websites without Javascript is very rare today, I guess.
Help us to help you!
Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.