- Posts: 6
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Record responses as audio
- audiolime
- Topic Author
- Offline
- New Member
Less
More
12 years 2 months ago #71422
by audiolime
Record responses as audio was created by audiolime
Hi,
I am planning to conduct a study on difficult sentence processing and we are interested in how participants read out a number of sentences aloud.
Now as we want to conduct the study online, the sentences would be administered in written form but participants responses would have to be recorded as audio files.
I know there are plugins to play audio files in limesurvey but i haven't found anything on actually recording audio-responses.
Could you help me out here, any help would be great!
Best,
audiolime
I am planning to conduct a study on difficult sentence processing and we are interested in how participants read out a number of sentences aloud.
Now as we want to conduct the study online, the sentences would be administered in written form but participants responses would have to be recorded as audio files.
I know there are plugins to play audio files in limesurvey but i haven't found anything on actually recording audio-responses.
Could you help me out here, any help would be great!
Best,
audiolime
The topic has been locked.
- audiolime
- Topic Author
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
12 years 2 months ago #71427
by audiolime
Replied by audiolime on topic Record responses as audio
Hi all,
I found an applet that does exactly what I need: Nanogong . Is there any way to implement this into limesurvey?
Any hints or advice is greatly appreciated!
Esther
I found an applet that does exactly what I need: Nanogong . Is there any way to implement this into limesurvey?
Any hints or advice is greatly appreciated!
Esther
The topic has been locked.
- TMSWhite
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 84
- Thank you received: 21
12 years 2 months ago #71434
by TMSWhite
If you depend upon LimeSurvey or the support team, please give generously to our 2012 fundraiser .
Replied by TMSWhite on topic Record responses as audio
Esther-
If you have (or have access to) the PHP skills (or can make a suitable donation to LimeSurvey and find a developer who has bandwidth), adding Nanogong shouldn't be too hard. You would probably want to store a binary file, so you'd need a BLOB datatype, and none of the existing question types use that. So, you'd need to create a new question type to store the BLOB. I had to create the Equation question type a few months back, and it only took a few day's effort.
However, a lot depends on your timing. We're nearly ready to release version 1.92, which (knock on wood) will be the last in the 1.xx series. We're also nearing release of 2.0 alpha, which uses an entirely new framework. So, if you need something soon, you'd need to use the 1.xx approach, but it would need to be ported to 2.x. If you can wait about 3 months, it might be possible to build it directly into the 2.0 branch.
/Tom
If you have (or have access to) the PHP skills (or can make a suitable donation to LimeSurvey and find a developer who has bandwidth), adding Nanogong shouldn't be too hard. You would probably want to store a binary file, so you'd need a BLOB datatype, and none of the existing question types use that. So, you'd need to create a new question type to store the BLOB. I had to create the Equation question type a few months back, and it only took a few day's effort.
However, a lot depends on your timing. We're nearly ready to release version 1.92, which (knock on wood) will be the last in the 1.xx series. We're also nearing release of 2.0 alpha, which uses an entirely new framework. So, if you need something soon, you'd need to use the 1.xx approach, but it would need to be ported to 2.x. If you can wait about 3 months, it might be possible to build it directly into the 2.0 branch.
/Tom
If you depend upon LimeSurvey or the support team, please give generously to our 2012 fundraiser .
- Expression Manager (EM):
Documentation
|
Sample Surveys
|
How Tos
|
Show Logic File
|
Upgrading to 1.92+ - Excel Style for Survey Structure Import/Export
The topic has been locked.
- Mazi
- Offline
- Official LimeSurvey Partner
12 years 2 months ago #71585
by Mazi
Best regards/Beste Grüße,
Dr. Marcel Minke
Need Help? We offer professional Limesurvey support: survey-consulting.com
Contact: marcel.minke(at)survey-consulting.com
Replied by Mazi on topic Record responses as audio
The easy way would be to link to their demo page at
gong.ust.hk/nanogong/nanogong42.html
from within the survey, telling them to record the voice and store the file locally. Then use a file upload question type at Limesurvey and let them upload their file.
Best regards/Beste Grüße,
Dr. Marcel Minke
Need Help? We offer professional Limesurvey support: survey-consulting.com
Contact: marcel.minke(at)survey-consulting.com
The topic has been locked.
- audiolime
- Topic Author
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
12 years 2 months ago - 12 years 2 months ago #71632
by audiolime
Replied by audiolime on topic Record responses as audio
Thank you to both of you for your time and consideration! I finally managed to integrate the applet into a text-only style question.
The Nanogong setup was explained very well on their website, the only thing that was a little bit difficult was to get the path right so that limesurvey could find the applet. I did this with "codebase", if anybody else wants to try it I can send you the code I used.
The next step will be to edit the name of the audio file the applet generates, I somehow need to pass on the value of limesurvey's {savedid} to the php script nanogong uses, if you have any ideas I would be very thankful: See my new post
Best regards,
Esther
The Nanogong setup was explained very well on their website, the only thing that was a little bit difficult was to get the path right so that limesurvey could find the applet. I did this with "codebase", if anybody else wants to try it I can send you the code I used.
The next step will be to edit the name of the audio file the applet generates, I somehow need to pass on the value of limesurvey's {savedid} to the php script nanogong uses, if you have any ideas I would be very thankful: See my new post
Best regards,
Esther
Last edit: 12 years 2 months ago by audiolime.
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10611
- Thank you received: 3690
12 years 2 months ago #71663
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 Record responses as audio
Answered - www.limesurvey.org/en/forum/can-i-do-thi...o-another-php-scriptI somehow need to pass on the value of limesurvey's {savedid} to the php script nanogong uses...
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- Mazi
- Offline
- Official LimeSurvey Partner
12 years 2 months ago #71677
by Mazi
When you are done, please post the link to the bugtracker ticket here.
Thanks!
Best regards/Beste Grüße,
Dr. Marcel Minke
Need Help? We offer professional Limesurvey support: survey-consulting.com
Contact: marcel.minke(at)survey-consulting.com
Replied by Mazi on topic Record responses as audio
Please open a ticket at our bugtracker at the "user patches" section and attach your code files there. The forum is cleaned up regularly so this might get lost if you post it here.audiolime wrote: The Nanogong setup was explained very well on their website, the only thing that was a little bit difficult was to get the path right so that limesurvey could find the applet. I did this with "codebase", if anybody else wants to try it I can send you the code I used.
When you are done, please post the link to the bugtracker ticket here.
Thanks!
Best regards/Beste Grüße,
Dr. Marcel Minke
Need Help? We offer professional Limesurvey support: survey-consulting.com
Contact: marcel.minke(at)survey-consulting.com
The topic has been locked.
- lime4nonprofit
- Offline
- New Member
Less
More
- Posts: 1
- Thank you received: 0
12 years 2 months ago #71980
by lime4nonprofit
Replied by lime4nonprofit on topic Record responses as audio
Would you mind sharing the code with me? I am trying to do the exact same thing without much luck.
-Thanks Bryan
-Thanks Bryan
The topic has been locked.
- audiolime
- Topic Author
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
12 years 2 months ago #71984
by audiolime
Replied by audiolime on topic Record responses as audio
Here, I have submitted my solution to the bugtracker:
[url=http://http://bugs.limesurvey.org/view.php?id=5663] bugs.limesurvey.org/view.php?id=5663 [/url]
The two code files you need are attached to the question, receiver.php and the nanogong question code that you copy into your limesurveys question source code field. If you still have problems, let me know!
[url=http://http://bugs.limesurvey.org/view.php?id=5663] bugs.limesurvey.org/view.php?id=5663 [/url]
The two code files you need are attached to the question, receiver.php and the nanogong question code that you copy into your limesurveys question source code field. If you still have problems, let me know!
The topic has been locked.
- audiolime
- Topic Author
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
12 years 2 months ago #71986
by audiolime
Replied by audiolime on topic Record responses as audio
Hi all,
I have a further question concerning this issue - I would like to modify the "next" button in the survey for the questions that require an audio recording. Everytime a participant clicks on "next", the script should check if a file with a specific name exists in a specific folder.
I wonder where I could make these changes to the next button, is that something for the question template? I think that once I figure out where to change the code the actual 'check-if-file-exists' will be pretty easy, I just don't know where to start.
I would be very thankful for some tips!
Best,
Esther
I have a further question concerning this issue - I would like to modify the "next" button in the survey for the questions that require an audio recording. Everytime a participant clicks on "next", the script should check if a file with a specific name exists in a specific folder.
I wonder where I could make these changes to the next button, is that something for the question template? I think that once I figure out where to change the code the actual 'check-if-file-exists' will be pretty easy, I just don't know where to start.
I would be very thankful for some tips!
Best,
Esther
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10611
- Thank you received: 3690
12 years 2 months ago - 12 years 2 months ago #71993
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 Record responses as audio
In the source of the question, add a click event handler for the Next/Submit buttons:
Code:
<script type="text/javascript" charset="utf-8"> $(document).ready(function() { // Interrupt next/submit function $('#movenextbtn, #movesubmitbtn').click(function(){ var url = 'path/to/audio/file.wav'; // Request the file var request = new XMLHttpRequest(); request.open('HEAD', url, false); request.send(); // Act on the request results if(request.status!=404 == false) { // File doesn't exist alert ('File does not exist!'); return false } else { // File exists return true } }); }); </script>
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 12 years 2 months ago by tpartner.
The following user(s) said Thank You: audiolime
The topic has been locked.
- audiolime
- Topic Author
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
12 years 1 month ago #73643
by audiolime
Replied by audiolime on topic Record responses as audio
wow, that's great! I just came back to this issue after working on other parts on the project, and it works beautifully! Thank you very much for the code.
I tried to adapt it to check for a file name that includes {SAVEDID} and {QID} (I am using 1.92 now), but somehow that code never generates the "File does not exist"- error.
I substituted the line:
with this line:
I tried to adapt it to check for a file name that includes {SAVEDID} and {QID} (I am using 1.92 now), but somehow that code never generates the "File does not exist"- error.
I substituted the line:
Code:
var url = 'path/to/audio/file.wav';
with this line:
Code:
var url = 'scripts/voice/v1_s' + {SAVEDID} + '_q' + {QID} '.wav';
The topic has been locked.