The web design and pages for my personal website.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

44 lines
1.5 KiB

  1. {% extends "layout.html" %}
  2. {% block title %}Download Manager{% endblock %}
  3. {% block content %}
  4. {% if method == "index" %}
  5. <h1>Project {{ project }}</h1>
  6. You are about to download the file <strong>{{ file }}</strong> from the
  7. project <strong>{{ project }}</strong>. This file has been downloaded
  8. {{ hits }} time(s).
  9. <h1>Download</h1>
  10. To continue your download, click on the button below.
  11. <br><br><br>
  12. <form name="download" action="/download" method="POST">
  13. <input type="hidden" name="token" value="{{ csrf_token() }}">
  14. <input type="hidden" name="method" value="get">
  15. <input type="hidden" name="project" value="{{ project }}">
  16. <input type="hidden" name="file" value="{{ file }}">
  17. <span style="background-color: #88AADD; padding: 15px; border-top: 2px solid #006699;
  18. border-left: 2px solid #006699; border-right: 2px solid #AACCFF; border-bottom: 2px solid #AACCFF">
  19. <button type="submit">Download Now</button>
  20. </span>
  21. </form>
  22. {% elif method == "get" %}
  23. <h1>Downloading File...</h1>
  24. Your download of <strong>{{ file }}</strong> will begin shortly. If it doesn't,
  25. <a href="/projects/{{ project }}/{{ file }}">download it directly</a>.
  26. {% endif %}
  27. {% endblock %}
  28. {% block scripts %}
  29. {% if method == "get" %}
  30. <script>
  31. $(document).ready(function() {
  32. window.location.href = "/projects/{{ project }}/{{ file }}";
  33. });
  34. </script>
  35. {% endif %}
  36. {% endblock %}