- Posts: 3
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Validition against given list of numbers e.g. employee numbers, receipt numbers
- mohammedrabia
- Topic Author
- Offline
- New Member
Less
More
7 years 7 months ago #141103
by mohammedrabia
Validition against given list of numbers e.g. employee numbers, receipt numbers was created by mohammedrabia
Good Day!
It would be great if someone could shed some light on how do i go about verifying numbers against a list of numbers.
e.g.
I would want to have a validation of the employee number entered by the user against a list/database of users to ensure that it is an employee of the company and not a contractor or a partner employee staff.
Is this possible on the limesurvey? If so, how do I go about this validation in any way?
Appreciate any help in the matter.
Thanks a bunch.
M.
It would be great if someone could shed some light on how do i go about verifying numbers against a list of numbers.
e.g.
I would want to have a validation of the employee number entered by the user against a list/database of users to ensure that it is an employee of the company and not a contractor or a partner employee staff.
Is this possible on the limesurvey? If so, how do I go about this validation in any way?
Appreciate any help in the matter.
Thanks a bunch.
M.
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10098
- Thank you received: 3589
7 years 7 months ago #141111
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Validition against given list of numbers e.g. employee numbers, receipt numbers
There is nothing built in to LimeSurvey to validate against an external database. You will need to make an AJAX call to a remote file that queries the external DB.
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- mohammedrabia
- Topic Author
- Offline
- New Member
Less
More
- Posts: 3
- Thank you received: 0
7 years 7 months ago #141113
by mohammedrabia
Replied by mohammedrabia on topic Validition against given list of numbers e.g. employee numbers, receipt numbers
I would want to verify against an excel sheet or csv file or any flat file which would be present on the same machine? Is this still possible with the build in features of limesurvey? If not, could you please direct me as to how would i be able to accomplish it.
Thanks in Advance,
M.
Thanks in Advance,
M.
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10098
- Thank you received: 3589
7 years 7 months ago #141115
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Validition against given list of numbers e.g. employee numbers, receipt numbers
Although for a different purpose, some of these workarounds may give you insight on how to access a remote CSV file via JavaScript -
manual.limesurvey.org/Workarounds:_Manip...wers_for_text_inputs
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- mohammedrabia
- Topic Author
- Offline
- New Member
Less
More
- Posts: 3
- Thank you received: 0
7 years 7 months ago #141133
by mohammedrabia
Replied by mohammedrabia on topic Validition against given list of numbers e.g. employee numbers, receipt numbers
Thanks Tpartner....
==================================
Environment:
Limesurvey Version 2.50+ Build 160718
==================================
Well, I am currently working on the an Arabic survey and on input of the variable as specified "{INSERTANS:877769X101X886}" according to the link provided:
<script type="text/javascript" charset="utf-8">
alert("{INSERTANS:877769X101X886}");
</script>
I run into the following output string:
<span id='LEMtailor_Q_886_43'>23412342134</span>
rather than it giving me the following output string:
23412342134
as specified in the document. Any idea what I may be doing wrong. I tried using "{INSERTANS:{SGQ}}" again to no avail...
Any help would great....
==================================
Environment:
Limesurvey Version 2.50+ Build 160718
==================================
Well, I am currently working on the an Arabic survey and on input of the variable as specified "{INSERTANS:877769X101X886}" according to the link provided:
<script type="text/javascript" charset="utf-8">
alert("{INSERTANS:877769X101X886}");
</script>
I run into the following output string:
<span id='LEMtailor_Q_886_43'>23412342134</span>
rather than it giving me the following output string:
23412342134
as specified in the document. Any idea what I may be doing wrong. I tried using "{INSERTANS:{SGQ}}" again to no avail...
Any help would great....
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10098
- Thank you received: 3589
7 years 7 months ago #141157
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Validition against given list of numbers e.g. employee numbers, receipt numbers
Expression Manager wraps piped text in <span> elements. You should be able to clean it up something like this (untested):
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.