Good morning! I have this script that lists all the links of a page, but does not bring the name of the link but only the address, can you name the link instead of the address?
javascript: var a = document.getElementsByTagName('a');var b = a.length; if(b != 0){ document.write('<h1> Lista de Links </h1> '); for (i = 0; i < b; i++){ document.write('<pre><a href=\'' + a[i] + '\'>' + a[i] + '</a>' + '</pre> ');}} else{ document.write('Nenhum link encontrado');}