Welcome to the LimeSurvey Community Forum

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

Search Results (Searched for: test)

  • Stiegi64
  • Stiegi64's Avatar
20 Jun 2023 20:35
Hallo holch,

ich habe ein ähnliches Problem wie helpmels. Leider konnte ich deine Erklärung nicht ganz nachvollziehen (Ich beziehe mich nachfolgend auf deinen 2. Ansatz). Was ist eine Formelfrage (also welcher Fragetyp) und was genau muss ich einstellen, sobald ich die Frage vom Typ Multiple Answers erstellt habe? Könntest du das Vorgehen bitte etwas genauer ausführen (oder wenn es dir zeitlich möglich ist, eine Vorlage hochladen, anhand der ich das Prinzip erkennen kann)?

In meinem Fall gibt es einen kleinen Unterschied zur Schilderung von helpmels: Wenn bei Frage 1 A oder B ausgewählt wird, soll X,Y und Z angezeigt werden. Wenn C ausgewählt wird, soll nur X und Y angezeigt werden.

Freundliche Grüße
Stiegi

PS: Ich nutze Version 4.3.19
  • Joffm
  • Joffm's Avatar
20 Jun 2023 18:01 - 20 Jun 2023 18:10
Hallo,
zunächst Zustimmung zu holchs Ausführungen.
Ich wüsste auch nicht, wie ich es beantworten soll in einer Matrix, wo in jeder Zeile genau eine Antwort ausgewählt wird.

Oder willst Du eine Matrix nach Spalten benutzen? Dann musst Du dies auch sagen.
Dann könntest Du ja einfach separate Fragen stellen.

Aber da holch mir den Ball ja wieder elegant zugespielt hat, empfehle ich Dir mein "Tutorial 3: Gimmicks", Kapitel über Conjoint.(tinyslider und slick)
Du findest es hier auf einer der folgenden Seiten (6, 7 oder so)

Und gleich zu Anfang wird dort gezeigt, wie Du die Bildschirmbreite erkennen kannst, um eine Art Weiche zu benutzen:
Breiter Bildschirm - Matrix
Schmaler Bildschirm - einzelne Fragen

Joffm 
 
  • holch
  • holch's Avatar
20 Jun 2023 16:53
One other thing:

It's for an individual participant, so it seemed a lot of clicking to export as csv and import it into Limesurvey that way for 1 person.


As far as i know, you don't necessarily need to export the CSV, add a respondent and then import it again.

As far as I know you can save one step here and you could just upload a CSV (in the right format of course, but you have that anyway, because you should have the original CSV saved) and just update the participant table with this one respondent. Might save you at least some steps and as far as I know should work. You might want to make that test.
  • holch
  • holch's Avatar
20 Jun 2023 15:38

But I've now changed to the 8.1 version. Still, the same issue persists.


As I said, it might not have anything to do with your issue.

So your bug report is still valid. But I would update it with the information that this also happens with PHP 8.1 because I am sure the first thing they will ask you is to test with PHP 8.1. As you have done this already, let the developers know in the bug report and speed things up.

Oh, i just checked and you did it already. Great!
  • holch
  • holch's Avatar
20 Jun 2023 15:31
Replied by holch on topic Anonymity and IP-addresses
I usually do not use the anonymous mode in Limesurvey, so take this with a grain of salt.

Afaik, in anonymous mode IP addresses won't be stored, no matter what you set in the IP address setting, but you should test this on your own by activating your survey and do some test runs to see what is actually saved. But I will try to answer your questions about IP addresses anyway.

1) What’s the difference between not saving IP-address and anonymizing the IP-address?


If you anonymize the IP-address Limesurvey will cut of the last 3 (I think) digits of the IP address. So you still have some information regarding the IP address, you at least could research the block of IP addresses, etc. So in your case, if you want it totally anonymous, you should NOT save the IP address. But as I said, I think if you choose anonymous mode you shouldn't be able to save the IP address anyway. Or a dummy IP address is saved. But test it yourself. Takes you 5 minutes.

2) What’s the point/advantage of registering or saving the IP-address and/or the referrer URL if my survey is supposed to be anonymous?


None, actually you shouldn't save it (and in my opinion you can't if you use anonymous mode). Saving the IP address and referrer can be relevant in many cases, but it would undermine your clame of anonymity.

3) Is my survey anonymous at all if I chose to save the IP-addresses or save the referrer URL? (I guess not)?Looking forward to hear from somebody more experienced than me.


If you save the IP address and referrer URL in your survey in any way it is probably not anonymous in a technical way anymore. However, I thinks far more important than the technical anonymity (there is always some way around it anyway) it "ethical" anonymity. As a professional market researcher I guarantee my respondents anonymity, despite the technical possibility to connect personal data with response data. However, based on the ESOMAR code of conduct I guarantee that we treat personal data separate from research data, so we won't analyze the information together with any personal data. Could we connect them both? Yes. Do we do it? No.

However, often you need to have at least some connection between personal identifiers and survey data, for example for quality control (e.g. in field research where we call a certain percentage of respondents to make sure their response is real, that they were treated well by the interviewer, that the interviewer was professioanl, etc.), to be able to invite them to a follow up survey, to be able to provide them with a "thank you" or prize, etc. Never the less, data is never connected to personal identifiers during analysis, which is what counts I think.

I know, some people want (or have to) gurantee 100% "technical" anonymity. Then you will have to go down the route of the "anonymous" mode with all its advantages and disadvantages.

But the issue there is, that if someone is malicous, they can always find a way around the technical anonymity if they really want to (e.g. pass on personal data via the URL and hide it in hidden question in the survey, use javascript and trackers to get to the IP address, etc.).
  • holch
  • holch's Avatar
20 Jun 2023 15:02 - 20 Jun 2023 15:04
Don't worry. It is not a big deal. Your "it is not convenient" just sounded a little odd so I made a snide comment. 

The thing with LSS files is that it can save us a lot of back and forth. Because experience shows, that people usually only tell us "half the story" in the forum. Often we see a lot of back and forth that could have actually be solved quite quickly with a simple LSS export.

And just so you know: we totally understand that you can't (or don't want to) share your complete survey.

Actually, as I said, we prefer not to have the whole survey, but rather a copy with only the relevant parts (and the questions and answeroptions can be "anonymized", or if it is easier, a quick mockup of the issue.

At the end, this was not the case here, but sometimes we have an idea on how to solve the issue, but would need to test and play around ourselves. Then a small sample survey comes very handy, as we don't have to create a mockup based on your described scenario (which at the end might be different as we imagined) and can directly work on your base design.

However, in your second explanation it seems like you could convey your issue in a way that we could understand it and find a solution.

So I assume you could solve your issue? If not, let us know. We are both generally quite friendly and don't bite, at least most of the time. :-)
  • fesojt
  • fesojt's Avatar
20 Jun 2023 09:12 - 20 Jun 2023 15:10
SPS-Erstellung Unicode-Problem? was created by fesojt
Bitte helfen Sie uns, Ihnen zu helfen und füllen Sie folgende Felder aus:
Ihre LimeSurvey-Version: 5.6.2+230125
Eigener Server oder LimeSurvey-Cloud: Eigener Server
Genutzte Designvorlage: Erweiterte Fruity-Vorlage
==================
Hallo zusammen,

bei einem Testexport (SPSS via SPS+DAT) aus der Antworten einer Abfrage bin ich darüber gestolpert, dass in der erzeugten SPSS-Datendatei bei offenen Antworten häufig ein, manchmal keins und vereinzelt mehrere Zeichen abgeschnitten wurden. Händisch kann ich das beheben, indem ich in der Syntax-Datei jeweils hinter dem "A" die Zahl anpasse, die offenbar die Spaltenbreite angibt. Dann wird korrekt exportiert. Auch sieht die DAT-Datei in Notepad geöffnet gut aus, ebenso wie der Excel- und der CSV-Export.
Die Zahl der abgeschnittenen Zeichen entspricht in jedem überprüften Fall der Zahl an Umlauten + ß, die sich in der Antwort finden. Mein Schluss ist, dass die automatische Zeichenzählung, die die SPS-Datei "vorbereitet" diese Zeichen nicht als solche erkennt. (EDIT: Die Zeichen werden erkannt, aber nur als EINS, aber man "benötigt" offenbar zwei für Umlaute. Somit hat man pro Umlaut ein Zeichen zu wenig). Da das Ganze bereits bei der Erstellung der Syntax-Datei erfolgt, denke ich, dass auch der Unicode-Befehl in der Syntax oder in SPSS keine Abhilfe schaffen kann.
Hat jemand einen Hinweis, ob und wenn ja wo, man sich diesem Problem einmal widmen könnte?

Vielen Dank für die Hilfe!
  • Joffm
  • Joffm's Avatar
19 Jun 2023 11:29 - 19 Jun 2023 11:30
Hallo,
ich habe noch etwas nachgedacht und herumgespielt.
Die erste Lösung ist m.E. vorzuziehen.
Siehe hier
[url] manual.limesurvey.org/Tab_Separated_Value_survey_structure [/url]
Und ich denke, Du solltest diesem hier nicht folgen

 Hint: Columns id and related_id are used only for quota and are optional. If you don't have quota, you can directly remove this 2 columns.

sondern diese beiden Spalten nur leeren.

Die andere Lösung geht auch ziemlich easy.
Vorteilhaft ist die Vorbesetzung (hier QPool genannt) nicht zeilenweise anzuordnen, sondern direkt hintereinander

111112113114115121122123124125131132133134135141142143144145151152153154155211212213214215221222223224225231232233234235241242243244245251252253254255311312313314315321322323324325331332333334335341342343344345351352353354355411412413414415421422423424425431432433434435441442443444445451452453454455511512513514515521522523524525531532533534535541542543544545551552553554555
Dann musst Du die Zeichen für "Carriage Return" und "Linefeed" nicht berücksichtigen.

Dann würde für alle Fragen die Antwortoption 1 folgendermaßen aussehen
{if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),0,1)==1,"Krankeit A1", if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),0,1)==2,"Krankeit A2", if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),0,1)==3,"Krankeit A3", if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),0,1)==4,"Krankeit A4", if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),0,1)==5,"Krankeit A5","")))))}

Antwortoption 2
{if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),1,1)==1,"Krankeit B1",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),1,1)==2,"Krankeit B2",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),1,1)==3,"Krankeit B3",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),1,1)==4,"Krankeit B4",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),1,1)==5,"Krankeit B5","")))))}

Antwortoption 3
{if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),2,1)==1,"Krankeit C1",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),2,1)==2,"Krankeit C2",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),2,1)==3,"Krankeit C3",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),2,1)==4,"Krankeit C4",if(substr(substr(QPool,(self.sq_1.qseq-1)*3,3),2,1)==5,"Krankeit C5","")))))}

Die Krankheitsnamen mit den evtl. Tooltips musst Du entsprechend einfügen.
In der Vorbesetzung kannst Du die Kombination ja auch ein bisschen durcheinanderwürfeln.

Joffm

Der Editor schafft es einfach nicht "gleich 3" vernünftig darzustellen.
  • xevolic
  • xevolic's Avatar
19 Jun 2023 11:15
Please help us help you and fill where relevant:
Your LimeSurvey version: 6.1.2 / 6.1.3 (master)
Own server or LimeSurvey hosting: own server
Survey theme/template: default
==================
We have used LimeSurvey for few years and wanted to upgrade it to the newest version: 6.1.2
Unfortunately we encountered problem with attaching files to survey's e-mail templates.

The problem exists on our web server with our database and even in local Docker version with demo records.
I tested LimeSurvey in Docker with PHP 8.2 and 7.4

For the demo purpose I had created new survey, which got id 275838, and then I went to link:
limesurvey-demo.loc/index.php/admin/emai...ndex/surveyid/275838

File manager loads correctly from time to time (see attached screenshots) in Firefox.
In Google Chrome it can cause tab crash.

Files can be successfully uploaded, but I cannot choose them and attach below the form (by double click or choosing Select from the context menu).

Have you experienced such strange behaviour?

I cannot see any errors in JavaScript console.
  • lfanfoni
  • lfanfoni's Avatar
16 Jun 2023 17:31
Senza usare l'obbligatorietà standard dell'intera domanda, puoi usare l'Equazione di convalida della domanda per inserirci una condizione scritta con l'Expression Manager. La funzione per testare se un campo è vuoto è la is_empty. Per far riferimento alle caselle di testo di ogni riga della domanda array, vedi il manuale qui: manual.limesurvey.org/Expression_Manager#Qcode_Variable_Naming

Forse potrebbe funzionare anche la funzione count sull'intero array, magari prima prova questa
  • mferraz
  • mferraz's Avatar
15 Jun 2023 18:52
Please help us help you and fill where relevant:
Your LimeSurvey version: 6.1.3+230612 
Own server or LimeSurvey hosting:
Survey theme/template:
==================
Hi

I'm trying to implement the following code to Authenticate users using Shibboleth like we used to do on version 3, but I'm getting the following error when I've tried to test the shibd user variable:PHP warningUndefined array key "eppn"/opt/limesurvey/plugins/AuthAAI/AuthAAI.php(20)08 public $allowedPublicMethods = array();
09
10 public function init()
11 {
12 // Registra os eventos que o plugin vai escutar
13 $this->subscribe('beforeLogin');
14 $this->subscribe('newUserSession');
15
16 }
17
18 public function beforeLogin()
19 {
20 echo $_SERVER;
21 // Verifica se a variável $_SERVER existe
22 if (isset($_SERVER)) {
23 // Usa a variável como username
24 $username = $_SERVER;
25 // Tenta encontrar o utilizador no banco de dados
26 $user = $this->api->getUserByName($username);
27 if ($user === null) {
28 // Se o utilizador não existe, cria um novo com permissão de participante
29 $user = new User;
30 $user->users_name = $username;
31 $user->password = hash('sha256', createPassword());
32 $user->full_name = $_SERVER;
Stack Trace#0 unknown(0): AuthAAI->beforeLogin()#1–
  /opt/limesurvey/application/libraries/PluginManager/PluginManager.php(269): call_user_func(array(AuthAAI, "beforeLogin"))264 if (
265 !$event->isStopped()
266 && (empty($target) || in_array(get_class($subscription[0]), $target))
267 ) {
268 $subscription[0]->setEvent($event);
269 call_user_func($subscription);
270 }
271 }
272 }
273
274 return $event;
#2–
  /opt/limesurvey/application/controllers/admin/Authentication.php(111): LimeSurvey\PluginManager\PluginManager->dispatchEvent(PluginEvent)106 // In Authdb, the plugin event "beforeLogin" checks if the url param "onepass" is set
107 // if yes, it will call AuthPluginBase::setAuthPlugin to set to true the plugin private parameter "_stop", so the form will not be displayed
108 // @see: application/core/plugins/Authdb/Authdb.php: function beforeLogin()
109 $beforeLogin = new PluginEvent('beforeLogin');
110 $beforeLogin->set('identity', new LSUserIdentity('', ''));
111 App()->getPluginManager()->dispatchEvent($beforeLogin);
112
113 /* @var $identity LSUserIdentity */
114 $identity = $beforeLogin->get('identity'); // Why here?
115
116 // If the plugin private parameter "_stop" is false and the login form has not been submitted: render the login form
#3–
  /opt/limesurvey/application/controllers/admin/Authentication.php(47): Authentication::prepareLogin()42 }
43 // The page should be shown only for non logged in users
44 $this->redirectIfLoggedIn();
45
46 // Result can be success, fail or data for template
47 $result = self::prepareLogin();
48
49 $isAjax = isset($_GET) && $_GET == 1;
50 $succeeded = isset($result[0]) && $result[0] == 'success';
51 $failed = isset($result[0]) && $result[0] == 'failed';
52
#4 unknown(0): Authentication->index()#5+
  /opt/limesurvey/vendor/yiisoft/yii/framework/web/actions/CAction.php(115): ReflectionMethod->invokeArgs(Authentication, array())#6+
  /opt/limesurvey/application/core/SurveyCommonAction.php(83): CAction->runWithParamsInternal(Authentication, ReflectionMethod, array("sa" => "login"))#7+
  /opt/limesurvey/vendor/yiisoft/yii/framework/web/CController.php(308): SurveyCommonAction->runWithParams(array("sa" => "login"))#8+
  /opt/limesurvey/vendor/yiisoft/yii/framework/web/CController.php(286): CController->runAction(Authentication)#9+
  /opt/limesurvey/vendor/yiisoft/yii/framework/web/CController.php(265): CController->runActionWithFilters(Authentication, array())#10+
  /opt/limesurvey/application/controllers/AdminController.php(202): CController->run("authentication")#11+
  /opt/limesurvey/vendor/yiisoft/yii/framework/web/CWebApplication.php(282): AdminController->run("authentication")#12+
  /opt/limesurvey/vendor/yiisoft/yii/framework/web/CWebApplication.php(141): CWebApplication->runController("admin/authentication/sa/login")#13+
  /opt/limesurvey/vendor/yiisoft/yii/framework/base/CApplication.php(185): CWebApplication->processRequest()#14+
  /opt/limesurvey/index.php(161): CApplication->run()
This is the code:
<?php
// Plugin para autenticação federada shibboleth para o limesurvey
class AuthAAI extends AuthPluginBase
{
    protected $storage = 'DbStorage';
    static protected $description = 'Autenticação federada shibboleth';
    static protected $name = 'AuthAAI';
    public function init()
    {
        // Registra os eventos que o plugin vai escutar
        $this->subscribe('beforeLogin');
        $this->subscribe('newUserSession');

    }

    public function beforeLogin()
    {
    echo $_SERVER; //for testing
        // Verifica se a variável $_SERVER existe
        if (isset($_SERVER)) {
            // Usa a variável como username
            $username = $_SERVER;
            // Tenta encontrar o utilizador no banco de dados
            $user = $this->api->getUserByName($username);
            if ($user === null) {
                // Se o utilizador não existe, cria um novo com permissão de participante
                $user = new User;
                $user->users_name = $username;
                $user->password = hash('sha256', createPassword());
                $user->full_name = $_SERVER;
                $user->parent_id = 1;
                $user->lang = 'pt-PT';
                $user->email = $_SERVER;
                if ($user->save()) {
                    // Atribui a permissão de participante ao utilizador
                    Permission::model()->setGlobalPermission($user->uid, 'surveys', array('create_p'));
                    // Dispara o evento de novo utilizador
                    $this->getEvent()->set('newUser', true);
                } else {
                    // Se houver algum erro ao salvar o utilizador, mostra uma mensagem de erro
                    $this->getEvent()->set('error', 'Não foi possível criar o utilizador.');
                }
            }
            // Se o utilizador existe, autentica
            if ($user !== null) {
                // Dispara o evento de nova sessão de utilizador
        $this->setUsername($user);
                $this->setAuthSuccess($user);
            $this->setAuthPlugin(); // This plugin will handle authentication and skips the login form
            }
        } else {
            // Se a variável não existe, mostra uma mensagem de erro
            $this->getEvent()->set('error', 'Não foi possível obter a variável $_SERVER[\'eppn\'].');
        }
    }

    public function newUserSession()
    {
        // Obtém o utilizador autenticado
        $user = $this->getEvent()->get('user');
        if ($user !== null) {
            // Atualiza a última data de login do utilizador
            $user->setAttributes(array('last_login' => date('Y-m-d H:i:s')));
            $user->save();
        }
    }
}

I've tried the same echo, even with a function on the same Limesurvey parent directory, and I'm getting the variable just fine.

Thank you in advance.
  • domec_
  • domec_'s Avatar
15 Jun 2023 12:44 - 15 Jun 2023 12:45
Hello,

I have a multiple question with randomized order and I would like to fix an exclusive option "none of these"  at the end, before the option other


I tried to put the script in the source of question using the code in the following link (LS 3.X)
Workarounds: Manipulating a survey at runtime using Javascript - LimeSurvey Manual

Thanks
Domec
  • clemidim
  • clemidim's Avatar
14 Jun 2023 18:03
Mehrfachauswahl und Bewertung dieser was created by clemidim
Servus!
Ich suche eine Möglichkeit wie ich bei einem Quiz mit Mehrfachauswahl richtige und falsche Optionen angeben kann. Mein Forschungsdesign ist exemplarisch so:
Zuerst kommt ein Quiz um bestehendes Wissen zu testen z.B.:
Welche Zutaten brauchst du für ein Nutellabrot?
  • Ei (falsch)
  • Nutella (richtig)
  • Wasser (falsch)
  • Brot (richtig)
  • Senf (falsch)
Danach kommt ein Rezept wo die Zubereitung erklärt wird. Anschließend kommt das Quiz nochmal um testen zu können wie viele Antworten der Proband beim ersten Mal richtig hatte und wie viel nachdem er das Rezept gesehen hat.
 
Kann ich irgendwelche Einstellungen vornehmen um das später auswerten zu können?

Hilfe wäre lieb!
Vielen Dank!
  • holch
  • holch's Avatar
13 Jun 2023 17:23
Assessment scores are NEVER stored in the database. So if you would use the traditional "assessment" feature, you would have to store this in a hidden question or something anyway.

What you do is calculate your score in a (hidden once you tested and it works) equation question. This way it is stored in the database. You can check this if you activate your survey and put in some data. You'll see that the value will be stored in this equation question and you can work with it later (or even within the same survey).
  • free521521521
  • free521521521's Avatar
13 Jun 2023 11:35 - 13 Jun 2023 16:48
Replied by free521521521 on topic When import to SPSS26 there's a error 2269, 105 100
Yes, I am working on a MacSO Monterey,
I did not upgrade my MacOS recently, it worked well days ago.

I tried to put the sps and dat files in User level foder, and It works!

So I qutie confuse about this issue. Really want to know what's the problem.

I test more:
1. I export from SPSS (.sav), it works well and the label( variable name) is ok.
2. I export from the SPSS to sps and dat file. And input them from the User level folder, it works but with warning:

>Warning # 4463 in column 20.  Text: [XXXXXXXXX] YYYYYYYYYYYYY
>A label specified on the VAR LABELS command contains more than 256 bytes.  The
>label will be truncated to 256 bytes.

Could it be somewhere Labels code issue?
Displaying 1051 - 1065 out of 1117 results.

Lime-years ahead

Online-surveys for every purse and purpose