How to remove the title page of the header when loading the page via Ajax?

I am using Codeigniter 2 with modular extensions. I load all my pages through Ajax jQuery.

I load the page as follows:

<a href="#Add Products" onclick="addProduct()> Add Product</a>

In IE, the title page is set as My Admin Title # Add Products.

How to remove this fix for posts in IE header?

I want the title of my page to remain the same, just "My Admin Title".

+3
source share
3 answers

You might want to try different ways to set the header using jQuery:

$(document).attr('title','Whatever');  

OR

$(document)[0].title = 'Whatever';  

OR

$(document).get(0).title = 'Whatever';  
+1
source

You can access the title element by following these steps:

document.getElementsByTagName('title')[0].innerHTML = "My Admin Title";
+1
source

-

document.title = "Hello World!";

HTML-, , .

0

All Articles