How bypass php zip import to add resources ?

More
5 years 2 days ago #90078 by tpartner
tpartner replied the topic: How bypass php zip import to add resources ?

when i remove the :eq0 it applies to the whole survey.

Not the whole survey, only all text inputs on the current page.

Can you activate another sample survey?

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in to join the conversation.

More
5 years 2 days ago #90087 by hug
hug replied the topic: How bypass php zip import to add resources ?
You will find the activated survey here : cdlvg.free.fr/index.php?sid=33913&lang=fr

You just have to choose anyone of the answer in the radio list and time questions will appear.

Please Log in to join the conversation.

More
5 years 2 days ago #90088 by Ben_V
Ben_V replied the topic: How bypass php zip import to add resources ?
Hi,
It doesn't works if you just remove (or wrap as comment) this kind of code ?:

$('#answer33913X4X34').attr('readonly', 'readonly');


Benoît

EM Variables => bit.ly/1TKQyNu | EM Roadmap => bit.ly/1UTrOB4
Last Releases => 2.6x.x goo.gl/ztWfIV | 2.06/2.6.x => bit.ly/1Qv44A1
Demo Surveys => goo.gl/HuR6Xe (already included in /docs/demosurveys)
The following user(s) said Thank You: hug

Please Log in to join the conversation.

More
5 years 2 days ago #90092 by tpartner
tpartner replied the topic: How bypass php zip import to add resources ?
Yes, in the first question (ID 38), you have this which removes the attribute from all text inputs:
$(".text-short input.text").removeAttr('readonly');

But then in the second question (ID 44), you have this which overrides that and applies the attribute to the first question again:
$(".text-short:eq(0) input.text").attr('readonly', 'readonly');

The JavaScript will be fired sequentially as the page is rendered so any commands or functions will override previous ones.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: hug

Please Log in to join the conversation.

More
5 years 2 days ago #90152 by hug
hug replied the topic: How bypass php zip import to add resources ?
Ok ! It works perfectly now :D

I understand my mistake : i thought I could have set this parameter question by question.

One more time, but the last one for this question type, thank you very much you too for your help :)

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now
Join our Newsletter!