+ 6
How can I take an <a> tag in HTML and make that tag's href attribute repeat every 10 seconds?
16 Answers
+ 6
Do you want to spam people or irritate a friend? 😂
+ 5
To open the link, or what?
+ 4
What do you mean, the link repeated?
+ 4
No, but wondering how ads can be opened every 10 secs
+ 3
Not actually, but the link to be repeated
+ 3
Yes
+ 3
Sort of
+ 3
Ok guys, I want a <a> tag to be repeated in the background while the user is on it... You understand, it opens every 10 seconds
+ 2
Soft of what?
+ 2
repeated means duplicate links ?
+ 2
Do you mean you open the link every 10 seconds? Wouldn't that be considered as spam?
+ 2
https://code.sololearn.com/Wr50w6AWFIm7/?ref=app
(Please don't tell anyone I gave you this code, please don't credit me.. 👺)
+ 1
Do you mean open the href link and refresh it evey 10sec?
+ 1
Try this on your pc
I haven't tested it yet
https://code.sololearn.com/WgIH7fhwDMJL/?ref=app
+ 1
If it works, run the function in a setInterval
and. boom, it opens every 10 seconds.
But most of the spam and adverts works with a onClick attribute. The onClick the function is temporarily not working so the user can do what they want, then resets after certain actions took place
0
use javascript setinterval method for that