How can I type 's in python
I am trying to pass the name of "Angela's Ashes" in a single bracket like below.
href="{{ url_for('cart', name = 'Angela's Ashes')}}"
Is there anyway to type in this without creating another variable?
Solution 1:
If this is a HTML template, you can try using double-quotes inside the {{ }}
- since those are within the template argument, only the template engine will see the quotes and it won't affect the HTML:
<a href="{{ url_for("cart", name = "Angela's Ashes") }}">