ios4 - Unable to play m4a file iPhone Device(Using iTunes affiliate search api) -


i trying play m4a(http://a1.phobos.apple.com/us/r1000/020/music/ad/41/da/mzm.fkekhvue.aac.p.m4a) file itunes affiliates using avaudioplayer can not able play it. think there issue link because have downloaded audio rename , hosted on server able play it.

i have tried web-view able play it. want play using avaudioplayer. when tried data link not able correct data.

also not able play using uiwebview or movieplayer(it working on simulator not in iphone device). , interesting not able play in safari app also.

i using itunes affiliate search api(e.g. http://ax.itunes.apple.com/webobjects/mzstoreservices.woa/wa/wssearch?term=jack+johnson.)

any idea?

thanks, dipen patel

i've had success using nsdata:

nsdata *musicdata = [nsdata datawithcontentsofurl:previewurl];  nserror *err; avaudioplayer *player = [[avaudioplayer alloc] initwithdata:musicdata error:&err]; 

Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -