Audio from web doesn't work

Hello!

I’m expiriencing problem with card sounds that contains links to web - it doesn’t play. But when i record some sound for card with my microphone it plays normally when i click show answer.

My back Template:

{{FrontSide}}

<hr id=answer>

{{Back}}

<div>{{Image}}</div>
{{Sound}}

In Sound field i have something like this:
[sound:htt@ps://audiocdn.lingualeo.com/v2/1/cHV0IG9mZg==b33a1f4d.mp3] (i added @ in https because i can’t post links here)
and it plays flawlessly if you just put it in browser

Please help, i am noob at it

The [sound:...] tag isn’t meant to stream remote media. Media - Anki Manual

To use that mp3 in your note/cards, you can:

  • Paste the url directly in the field. Anki will download the file to your collection media.
  • Download the file yourself and use the :paperclip: to attach it in that field. Anki will copy that file to your collection.

Either way, what you’ll end up with in the field is the resolved sound tag – [sound:cHV0IG9mZg==b33a1f4d.mp3] – and the mp3 will be added to your collection.

3 Likes

Thank you for reply! I downloaded a file, drag’n’dropped it into sound field and this word now works. But when i tried just to paste an URL to sound field it just added it as text to back template. Tell me, please, what am i doing wrong?

I have just imported 4500 words from another memorizing program and i can’t just download every word’s audio by hand, it will be nightmare. Maybe there is a way to automate it?


This is how it looks now

There is a sneaky thing that Anki does which is almost always helpful – if you copy text from a note field and paste it to note field, it assumes you want it formatted the same way. I think that’s what is getting in the way here. Try this –

  1. Copy just the url from the Sound field – from https through mp3
  2. Select (or delete) all of the text in the Sound field
  3. Paste that full url the Sound field using Ctrl Shift V (to strip the formatting)

That will help you in the future, but that’s obviously not going to be a scalable solution for 4500 notes.

It seems like you don’t actually have these files downloaded anywhere, is that right? In that case, you can pick your path forward forward –

(a) Let the media stay remote and use HTML audio tags instead. (You’ll always need to be connected to the internet for the audio to play.) I think you can do this with some careful Find and Replace-ing. If you’re not comfortable with regular expressions (regex), I can help you build a search that will work.
(b) Use the Localize Media add-on to download all of the media, attach it to your collection, and fix the sound tags.

3 Likes

Thank you very much! Localize Media is perfect for my task!

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.