JavaScript - - By Sam Deering

jQuery Get Current Page Title

jQuery code snippet to get the current web page full title and store it in a variable for use with other scripts. This is the title you see on your browser header.



Current page title: mytitle.

Another way suggested by Andy.

var current_href = $(location).attr('href');
var current_title = $(document).attr('title');
Sponsors
Login or Create Account to Comment
Login Create Account