debanjandhar12 / Obsidian-Anki-Sync

Obsidian plugin to make flashcards and sync them to Anki
GNU General Public License v3.0
140 stars 11 forks source link

Trouble with pasted / locally stored images #17

Open AUMmason opened 2 years ago

AUMmason commented 2 years ago

When adding pasted images or dragging images into my flashcards in obsidian they do not get rendered correctly in Anki?

I use this structure for my flashcards on a per file basis:

---
Deck: DeckName
---
<!-- basicblock-start-->
Question
::
Text + ![[Pasted Graphic]]
<!-- basicblock-end -->

When displaying the file in Anki it looks like this:

image

Not sure why this happens but I cannot get it to work unfortunately. Hope this issue can be solved 👍 Nice plugin btw!

mzietlow commented 1 year ago

Hi @AUMmason, I faced the same issue. As an alternative I also tried to use <img src="..." /> but '<' and '>' were encoded to &lt; and &gt; The solution for me was to upload the files to a hosting service and use the resulting URL as demonstrated here

busera commented 1 year ago

I have the same issues, images are not shown/rendered in Anki:

<!-- basicblock-start oid="ObsJ8bJXzt4rc7xA6VIOoS7Y" -->
Overview: Gradient Boosted Decision Trees (GBDT)::
- Test
- ![[../../../assets/Screenshot 2022-05-27 at 11.31.47.png]]
- ![](../../../assets/Screenshot%202022-05-27%20at%2011.31.47.png)
<!-- basicblock-end -->
Davidb-2107 commented 1 year ago

Hi @AUMmason, I faced the same issue. As an alternative I also tried to use <img src="..." /> but '<' and '>' were encoded to &lt; and &gt; The solution for me was to upload the files to a hosting service and use the resulting URL as demonstrated here

Hello, can you let met know which hoisting service do you use ? I've been trying with imgur but images are not showing.

Thanks

mzietlow commented 1 year ago

Hi @AUMmason, I faced the same issue. As an alternative I also tried to use <img src="..." /> but '<' and '>' were encoded to &lt; and &gt; The solution for me was to upload the files to a hosting service and use the resulting URL as demonstrated here

Hello, can you let met know which hoisting service do you use ? I've been trying with imgur but images are not showing.

Thanks

Did you try ![](https://i.imgur.com/bzKfi0z.png)? As a side note, I migrated to Pseudonium's Obsidian_to_Anki and am a less troubled person now (its also faster due to checking file-hashes)