I have created a success page on drupal 8 to download a file once redirected. Is there anyway to trigger downloading the file automatically based on a condition
For example if the page has an attribute download <a class="cta download-pdf" download="" href="/downloads/aim-brochure-mib.pdf">Download Brochure</a> inside the markup it would automatically download the file based on the address. Was thinking of using jquery/javascript to accomplish this.