I do'nt see the screenshot, also, you don't pass the posts and resources as parameters to render_template.
return render_template('resources2.html', posts=posts, resources=resources)http://flask.pocoo.org/docs/1.0/quickstart/#rendering-templates