Advertisement

TrimwebsolutionsTrimwebsolutions

Problem and Solutions

is it possible to redirect to another page with id from the previous page in js ?

By M.K. Verma · 3 May 2022

is it possible to redirect to another page with id from the previous page in js ?
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <div class="main">
      {% for data in library_dataset %} 
      Shop name:
      <br />
      <br />
      {{ data.shop_name }} <br />
      {{ data.adress }} <br />
      <td><a href="{% url 'update_shop' data.id  %}">
    <button type="button" class="btn btn-primary">Edit Shop Details</button>
    </a>
</td>

      {% endfor %}
    </div>
  </body>
</html>