How to get the title of an HTML page in JavaScript

1 Answer

0 votes
<head>
  <title>The Page Title</title>
</head>
console.log(document.title); 

  
    
    
/*
run:
    
The Page Title    
    
*/

 



answered Jun 12, 2021 by avibootz
...