WordPress/Mandigo/FAQ/How do I make the whole header clickable

From onehertz

Jump to: navigation, search

« Back to Mandigo

[edit] How do I make the whole header clickable?

Easy! Just add the following code into the first field on the HTML Inserts page:

<style type="text/css">
#headerimg {
	cursor: pointer;
}
</style>

<script type="text/javascript">
jQuery(document).ready(function() {
	jQuery('#headerimg').click(function() {
		window.location = 'http://www.yoursite.com/';
	});
});
</script>

Save options, and that's it!


You can also use

window.location = 'document.domain';

to get it to insert the current domain (includes subdomain), helpful in MU installations

Personal tools
sponsored links