<p>You can use the handy <a href="https://github.com/lindseydiloreto/craft-cpjs" rel="nofollow">Control Panel JS plugin</a> and add some JS that targets the <code>site-name</code> class on the anchor and removes it.  jQuery's <a href="https://api.jquery.com/removeAttr/" rel="nofollow">removeAttr</a> should do the trick.</p>

CC BY-SA 3.0
2016-06-20T17:40:56.960Z
2016-06-20T17:40:56.960Z
Brad Bell
<p>I'm looking to hook into this somehow to adjust the title home page link in the top left corner of the admin pages to stop opening in a new tab. Anyone have any good solutions for removing the <code>target="_blank"</code>?</p>

<p>Here's a sample of the code in question: </p>

<pre><code>&lt;div class="topbar"&gt;
    &lt;a class="site-name" href="http://sitename.com/" title="Site Homepage" target="_blank"&gt;
        &lt;h2&gt;Site Name&lt;/h2&gt;
     &lt;/a&gt;
&lt;/div&gt;
</code></pre>

<control-panel><admin>
Disabling the target="_blank" on admin site title link
# Disabling the target="_blank" on admin site title link

(Asked by: username_0 on 2016-06-20)

I'm looking to hook into this somehow to adjust the title home page link in the top left corner of the admin pages to stop opening in a new tab. Anyone have any good solutions for removing the target="_blank"?
Here's a sample of the code in question: 

    
        Site Name

**Tags:** control-panel, admin

---

## 1 answers

### Answer by username_1 on 2016-06-20. Score: 3 | Accepted answer

You can use the handy [Control Panel JS plugin](https://github.com/lindseydiloreto/craft-cpjs) and add some JS that targets the `site-name` class on the anchor and removes it. jQuery's [removeAttr](https://api.jquery.com/removeAttr/) should do the trick.


---

