Welcome, Guest
Username: Password: Remember me

TOPIC: Moving Surveys between surveys loses Conditions?

Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75141

  • tacman1123
  • tacman1123's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 125
  • Karma: 1
My workflow is to develop on a local machine first, then export the final survey to a live site.

I just spent a bunch of time creating a survey with a lot of conditional groups and questions. I exported it to a .lss file, but when I import it, I lose all the conditions.

I'm guessing that although the conditions can be written in EM as things like ((attendee_count > 0)), it gets mapped to the crazy SGQA index, and then lost because that variable is now irrelevant.

Is my logic correct? Are conditions lost when you move surveys?

That doesn't make sense, though, because other surveys with conditions are shared between installations.

I'm using 1.92 RC4.

Tac
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75142

  • TMSWhite
  • TMSWhite's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 82
  • Karma: 36
Please open a private bug report about this and attach the survey so that we can try to reproduce and fix the issue.
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75143

  • tacman1123
  • tacman1123's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 125
  • Karma: 1
False alarm. I think it was a configuration issue on the site it was moving to. Thanks!
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75164

  • tacman1123
  • tacman1123's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 125
  • Karma: 1
The problem was that I moved it to a site that was set for embedded surveys ($embedded=true in config.php), so the JS was never being loaded, and the conditional questions were never hidden, so it looked like conditions weren't working.

So embedding a survey in a CMS is a site-wide setting? Shouldn't conditions also work even if it's embedded? I guess the include file should bring that js in, can someone point me to documentation or examples for how to do that?

I guess I'm surprised that it's site-wide, I can imagine situation where some surveys are embedded and others use one of them lime templates to display the survey, or certainly different surveys.


Thx,

Tac
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75165

  • TMSWhite
  • TMSWhite's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 82
  • Karma: 36
Tac-

The javascript that controls question visibility (e.g. conditions) is generated in-line in the HTML page. There should be functions checkconditions() which calls ExprMgr_...(), which call a bunch of LEMrelNNN() and LEMvalNNN() functions

Is that JavaScript not being generated when embedded?

If it is being generated, then something else is going on. We usually debug such situations with FireBug. Alternatively, if you can provide a link to such a problem survey, we can take a look.

/Tom
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75166

  • tacman1123
  • tacman1123's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 125
  • Karma: 1
Can I send you links via a PM or email -- the survey isn't public yet? Or I can send the .lss file and you can import it into a site that's configured with $embedded=true.

I can be reached at tacman at gmail.

Thx,

Tac
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75168

  • tacman1123
  • tacman1123's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 125
  • Karma: 1
I added the following lines to config.php, to allow testing more easily:
$embedded = empty($_REQUEST['embedded']) ? false : $_REQUEST['embedded'];
$embedded_inc = '';             // path to a php file to include

And definitely if I add &embedded=1 in the url the conditional questions stop working.
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75224

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5325
  • Thank you received: 296
  • Karma: 249
tacman1123 wrote:
I added the following lines to config.php, to allow testing more easily:
$embedded = empty($_REQUEST['embedded']) ? false : $_REQUEST['embedded'];
$embedded_inc = '';             // path to a php file to include

And definitely if I add &embedded=1 in the url the conditional questions stop working.
Please test if the problem still exists at the latest release. If so please open a ticket at the bugtracker and...
  1. Give as much information as possible
  2. Attach your survey. You can mark your ticket "private" so that only the developers will be able to take a look at it.
  3. Provide step-by-step instructions how to reproduce the problem.
  4. If possible/helpful please provide screenshots

Afterwards please post the link to the bugtracker so we can follow the progress.

Thanks!

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75228

  • tacman1123
  • tacman1123's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 125
  • Karma: 1
The problem was actually that the server I moved it to was on RC5, the survey was developed on RC4, and there was a change in when group relevance was checked. TMSWhite fixed the problem last night.

So it was unrelated to embedding.

Tac
The administrator has disabled public write access.

Re: Moving Surveys between surveys loses Conditions? 2 years 7 months ago #75244

  • Mazi
  • Mazi's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 5325
  • Thank you received: 296
  • Karma: 249
Thanks for your feedback.

Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)limesurvey.org'"
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.232 seconds
Donation Image