Passing Dynamic Javascript Variable As Url In Template
I am trying to create a dynamic url in javascript to pass to my html template. In my js, I've got: // dynamic url to edit flashcard function createDynamicURL() { //The variab
Solution 1:
If you have the card object in your template, Try this :
<a id="edit-button" class="btn btn-default btn-warning" href="{% url 'flash-edit' card.id %}" >Edit</a>
Post a Comment for "Passing Dynamic Javascript Variable As Url In Template"