SHIVAPUTRA UDAGATTI
SHIVAPUTRA UDAGATTI

Reputation: 154

i have string containing html tags and i need to display that string in html page in web app2

I have string like in main.py: mystring="<ol><li>shiva</li><li>putra</li>"

and i want this value to display to in index.html using python webapp2. i have called {{mystring}} Now it is displaying as it is i.e: <ol><li>shiva</li><li>putra</li>

But I want output Like:

How would i display this please help me.

Upvotes: 1

Views: 65

Answers (1)

SHIVAPUTRA UDAGATTI
SHIVAPUTRA UDAGATTI

Reputation: 154

use safe keyword {{ mystring |safe}} it should work.

Upvotes: 2

Related Questions