LimeSurvey version: 6.16.15
Own server or LimeSurvey Cloud: Limesurvey CE on our own server
==================
Hello, we recently upgraded Limesurvey CE from 6.3.2 to 6.16.15.
In the admin page, the "survey search" function has been coded differently, creating a small issue we did not have before :
- in 6.3.2, the source code was <form class="" id="yw0"
action="/limesurvey-6.3.2/limesurvey/index.php/surveyAdministration/listsurveys" method="get">
- in 6.16.15, the source code is <form id="survey-search"
action="https://oursurveywebsite" method="get">
The problem is that, depending of our environnements where the limesurvey is running, the "action" link in the search button is sometimes with "http" and sometime with "http
s". When it is with http only, then occurs a warning in our web browser.
The source code extracted from the https://oursurveywebsite/index.php/dashboard/view page, allow us to see that other difference :
- LS.data = {
"baseUrl":"https
/\/oursurveywebsite","showScriptName":true,"urlFormat":"path"....} on our test environnement
- LS.data = {
"baseUrl":"http:\/\/oursurveywebsite","showScriptName":true,"urlFormat":"path"....} on our production environnement
This variable "
baseUrl" seems to constructed by the LimeScript.php file, from the Yii:app()getBaseUrl(true); function.
But my question is : why sometime it is built with https and sometime only http ?
(on our production environnement, we are behind a reverse proxy, that we don't have on our test environnement).
I had a look in config-defaults.php, up to force this value to the one we want, but , the only part that could fit is this one :
// === Advanced Setup
//The following url and dir locations do not need to be modified unless you have a non-standard
//LimeSurvey installation. Do not change unless you know what you are doing.
// The public URL is the URL that is used for anything that is facing a survey participant.
// It can be used to have a separation / distinction between a public URL for surveys and a private one for
// the administration - for example for certain proxy configurations or internal/external domain separation
if (!isset($argv[0]) && Yii::app() != null) {
$config 'publicurl' = Yii::app()->baseUrl . '/'; // The public website location (url) of the public survey script
} else {
$config 'publicurl' = '/';
}
But for the moment, I did not manage to make this work when I add it into the config.php file.
Thanks for you help.