Welcome to the LimeSurvey Community Forum

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

Im trying to embed an mp3 player in my limesurvey

  • drewxone
  • drewxone's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 7 months ago #98607 by drewxone
Hi, im new in limesurvey i just want to ask where will i put the HTML code for embedding mp3 to be played in my survey. im using limesurvey version 1.91 thanks in advance for helping.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
10 years 7 months ago - 10 years 7 months ago #98611 by tpartner
You can use a plugin like jPlayer to serve the audio files - www.limesurvey.org/en/forum/can-i-do-thi...reaming-advice#94628

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 10 years 7 months ago by tpartner.
The following user(s) said Thank You: drewxone
The topic has been locked.
  • drewxone
  • drewxone's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 7 months ago #98615 by drewxone
hi thanks for your reply but im getting this page(see attached file). it doesnt play. i imported your sample template and also the survey.

Attachment error.png not found

Attachments:
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
10 years 7 months ago #98618 by tpartner
Did you assign the survey to that template?

Do you get any JavaScript errors on the console?

Can you activate a test for us to see?

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • drewxone
  • drewxone's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 7 months ago - 10 years 7 months ago #98619 by drewxone
yes i already assign the survey for the dedicated template which is Demo_jPlayer_Integration. for your second question i dont know how to do it(sorry :( ) here's the link for the survey www.x-onesolutions.com/limesurvey/index.php?sid=447759&lang=en
Last edit: 10 years 7 months ago by drewxone. Reason: misspelled words
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
10 years 7 months ago #98625 by tpartner
Oh, sorry, I missed the fact that you are using 1.91.

That template is for 2.0, so you will need to follow the instructions on how to modify your template instead.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • drewxone
  • drewxone's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 7 months ago #98626 by drewxone
it's okay tony thanks ill get back to you when i'm still experiencing some problems i really appreciate your help
The topic has been locked.
  • drewxone
  • drewxone's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 7 months ago #98660 by drewxone
hi tony i follow all the instructions you provide in the forum link but when i created a new template i can't see it in my filezilla templates folder in limesurvey. that's why i don't know where to put my audio files and the jplayer stuffs.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
10 years 7 months ago #98661 by tpartner
Custom templates are placed in the limesurvey/upload/templates/ directory.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • drewxone
  • drewxone's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 7 months ago - 10 years 7 months ago #98664 by drewxone
In the group description or question source where you want a player to appear, add something like this where "question_1.mp3" is the desired audio filename. These <div> elements will be hidden by CSS and automatically detected by JavaScript which will insert the player.
<div class="audioSource">question_1.mp3</div>

how about that one, where will i put it? i have my audio folder under my custom template name and mp3 filename is 1.mp3 thanks tony
Last edit: 10 years 7 months ago by drewxone. Reason: add information
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
10 years 7 months ago #98665 by tpartner
In the source of the question or group description (depending on where you want the player to appear) - manual.limesurvey.org/Workarounds:_Manip....29_in_LimeSurvey.3F

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • drewxone
  • drewxone's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 7 months ago #98667 by drewxone
here's all the steps i finished:

1.creating audio directory in my custom template folder, created a skin folder(im using blue.moday skin) also pasted the jquery.jplayer.min.js and jplayer.swf

2.added this one to startpage.pstpl after {TEMPLATEJS}
<!-- jPlayer files -->
<link href="{TEMPLATEURL}(mydomainname)/limesurvey/upload/templates/(mycustometemplate)/skin/blue.monday/jplayer.blue.monday.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="{TEMPLATEURL}(mydomainname)/limesurvey/upload/templates/(mycustometemplate)/jquery.jplayer.min.js"></script>

3. added the code for template.js and template.css.

4. setting my survey template as my custometemplate name.

is there anything i forgot or missed?
should i removed the {TEMPLATEURL} in #2 or that is correct?
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose