0

I have no idea, my flask project writes in a specific flask session variable, called 'card', some data, that for each client I've to display on the client side.

1

1 Answer 1

0

Depends on your client side. But you can pass Python variables as arguments of the "return" :

@app.route("/")
def route_default():
    #some code here
    
    return render_template(index.html, myvar=session["card"])

then on your html file (index.html) refer to the variable between a double curl braket : {{myvar}} :

<h1>
    card name is : {{myvar}}
</h1>
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.