I'm George beginner in programming world and I need some help in this project.
So I'm building a script that at the end of it I want to redirect (on the same tab not in a new one) to the link (in this page is link.com in another page is link1.com and so on) inside of a href based on element class(e.g. class name aaa )
Every time the link is different but the class is always the same name : aaa (the class always contains only one link).
The methods I've tried seems to work only with clicks and copy the current pages url.
let url = location.href;
document.getElementsByClassName('aaa').innerHTML = url;
Only suitable extracting method I've found was Pythons BeautifulSoup Library.
Any thoughts on how am I going to extract the link ?
Thanks in advance.
