Anki create card even when the back template is empty

Cam Le's Avatar

Cam Le

18 Oct, 2019 04:42 AM

Hello everyone,

Recently I've been testing on the types of card using multiple fields for my subjects in university (specifically about microbiology). For every card i created multiple fields (Image: card1.jpg), but not every field has information so I left them empty at the back side of the card sometimes and thought that Anki would automatically not create that card but actually it did. I did some research on Anki Manual and get to know this code:
{{#FieldName}}
This text is only shown if FieldName has text in it
{{/FieldName}}

The problem is when I apply these to the back template of the card, Anki would always create the card even when there's no content within it. How can I set it up, so that when i don't type at some certain fields of the card, the cards are automatically removed? For example, in the image "card3.jpg" how can i adjust the commands so that when i leave the "Characteristics" box empty Anki will automatically remove card on this part?

Thank you very much for your help!

  1. 1 Posted by Cam Le on 18 Oct, 2019 04:49 AM

    Cam Le's Avatar

    For some reasons the image i attached didn't show up, you can see at following links:

    card1.jpg: https://imgur.com/49YR8hH
    card2.jpg: https://imgur.com/WerA9Af
    card3.jpg: https://imgur.com/NRFCWDI

  2. Support Staff 2 Posted by Damien Elmes on 18 Oct, 2019 06:53 AM

    Damien Elmes's Avatar

    Card creation is controlled by the front template only, so you need to wrap the front template in any required fields.

  3. 3 Posted by Cam Le on 20 Oct, 2019 02:58 PM

    Cam Le's Avatar

    It worked! Thank you very much!

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac