Inputs

  1. The base template defines title as a parameter. Flask/Jinja2 will not complain if you omit that; it'll be treated as the empty string.
  2. Inheriting templates:
    1. reading.html defines classdate and article
    2. inclass.html defines toc and content

Here's an example. For now, ignore the Unicode strings. I've removed all non-ASCII strings from the WMDB, which is why I asked you to re-load the WMDB above.

There's some additional trickery to turn a dictionary into a bunch of keyword arguments.

@app.route('/reading/')
def reading():
    stuff = {'title' : '''Material for class on St. Patrick's Day''',
             'date' : '3/17/2017',
             'article' : u'céad míle fáilte or a hundred thousand welcomes'}
    # The ** turns a dictionary into keyword arguments
    return render_template('reading.html', **stuff)