Category "jinja2"

HTML tbody only is only one header column width

I have a problem in HTML. I want to make a table with a fixed header and a scrollable body. The body (tbody) is composed of the rows of the table, and the head

FastAPI - How to render Jinja2 template with variable that contains special characters?

I'm trying to render this Jinja2 template: @app.get("/", response_class=HTMLResponse) async def read_root(request: Request, item: Optional[str] = None): ite

ImportError: cannot import name 'Markup' from 'jinja2'

When I recently deployed my project that includes Flask==1.0.2 and Jinja2>=2.10.1, I got the following error. It was running fine when I deployed it the prev

Pass variables to Flask's render_template

I want to pass multiple variables from my Flask view to my Jinja template. Right now, I can only pass one. How do I pass multiple variable when rendering a temp

Using <input> inside for loop in jinja flask

I am struggling to figure out how to access individual <input> elements, that have been created through a for loop. For example: <form id="score" metho

Changing the active class of a link with the twitter bootstrap css in python/flask

I got the following html snippet from my page template.html. <ul class='nav'> <li class="active"><a href='/'>Home</a></li>