I created a button that links to rederect.html and in there i created a link using <a href>
that has to be auto-clicked to go to index.html.
So when you are on index and used the button to get there you go to the rederect.html and automatically go back to index.html because the a href
has to auto-trigger. The only problem is that the <a href>
does not auto-trigger.
This is what i got so far:
<a href="index.html" class="banan" id="banan">Succesvol uitgelogt return naar login.</a>
<script type="text/javascript">
window.onload = function() {
$(function(){
window.location.href = $('.banan').attr('index.html');
});
}
</script>
I used the window.onload
event to try and trigger the function in there to trigger when you get on the redirect page. but it does not autorederect/click the <a href>
or give back any errors so i really don't know how to fix this.