Don
Posts: 0
Joined: Sun Feb 17, 2013 4:09 pm

change src on audio component to local storage var?

Sorry, I am having a bit of an issue with this one...

I have a label (hidden) that contains the full url to the audio file.
I have an image with an onclick JS event.

However, nothing happens when I click the image.
I am sure I have done something wrong... but just can not figure it out.

Your assistance is appreciated.

Image

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

change src on audio component to local storage var?

This is not correct

codevar vmailurl = $('[name="voicemail_msg8_link"]', element);/code

you would need to find Label with nesessary name in the same cell

codevar cell = $(this).parents('.cell-wrapper');
var vmailurl = $('[name="voicemail_msg8_link"]', cell).eq(0).text();/code

Don
Posts: 0
Joined: Sun Feb 17, 2013 4:09 pm

change src on audio component to local storage var?

Hi Marina,

I have tried your code above, but it does not return anything.

I have made the voicemail_msg8_link label visible, and there is a value in each... so I know that portion is working.

The issue does not appear to with the the link (as I use that same code on another page and it works), but with the player

precode
var player = $('[name="voicemail_player"]', element);
player&#46;append('<source src="'+ vmailurl +'" type="audio&#47;wav">');
/code/pre

Any thoughts?

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

change src on audio component to local storage var?

Hello! Please make your app link public (go to Test, check Public) and post the link here.

Don
Posts: 0
Joined: Sun Feb 17, 2013 4:09 pm

change src on audio component to local storage var?

Hi Marina,

Sorry for the delay, we could not open our projects.
As we are now back in, here is the link:

http://project.tiggzi.com/mobile-fram...

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

change src on audio component to local storage var?

Hi Don,
Thank you for the link. We'll take a look.

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

change src on audio component to local storage var?

On the image, there is an added JavaScript code that we adviced:codevar cell = $(this)&#46;parents('&#46;cell-wrapper');
var vmailurl = $('[name="voicemail_msg_link"]', cell)&#46;eq(0)&#46;text();

var player = $('[name="voicemail_player"]', element);
player&#46;append('<source src="'+ vmailurl +'" type="audio&#47;wav">');
player&#46;play();/code
Try deleting "element" in 3rd line:codevar player = $('[name="voicemail_player"]');/code

Don
Posts: 0
Joined: Sun Feb 17, 2013 4:09 pm

change src on audio component to local storage var?

I had tried that prior, but tried again.

On click of image is now:
precode
var cell = $(this)&#46;parents('&#46;cell-wrapper');
var vmailurl = $('[name="voicemail_msg_link"]', cell)&#46;eq(0)&#46;text();

var player = $('[name="voicemail_player"]');
player&#46;append('<source src="'+ vmailurl +'" type="audio&#47;wav">');
player&#46;play();
/code/pre

Still nothing happens :(

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

change src on audio component to local storage var?

Hello! Could you clarify some steps to reproduce, login/password because we've got error "Missing SiteID. Please enter a SiteID,
along with your phone service username and password." in Test tab of WS_voicemail service or you can send some sample of XML response so we can test it. If you don't want to post it here you can email it to a href="mailto:support@tiggzi.com" rel="nofollow"support@tiggzi.com/a

Return to “Issues”