Jump to content

Header Logo Link for Specific Pages

Recommended Posts

I've seen a similar question asked around the forums, but I think my situation is a little more complicated which is why I haven't gotten anything to work correctly. I am also using the Skye template.

I have two blogs, and for each blog I have set a unique logo in the header. Ideally, I'd like each unique logo to direct to a specific blog post. For example, the Wild Moon logo, when clicked, should go to the "Welcome to Wild Moon" post. I'm not sure how to implement a different link around the new logo, if it's even possible. The logo code is in the header section as such - 

Quote

<style>
.logo-image img
 {
 content:
url("https://blahblahblahlogo.jpeg");

 }
</style>

 

Link to comment
  • Replies 10
  • Views 684
  • Created
  • Last Reply

Add to Page Settings > Advanced > Header

<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.0/jquery.min.js"></script>
<script>
$(document).ready(function() {
	$('.site-title a').attr('href','https://beaverhero.com');
});
</script>

replace beaverhero with your blog page url

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Oops. Moved the </style> but it still doesn't want to work.

<style>
  .logo-image img
 {
 content: url("https://static1.squarespace.com/static/5f074ad37551af380fecaa89/t/5f248d886dd338649fdf75be/1596231048241/WildMoonWildJam.flair.v4.transparent-02.png");
 }
</style>

<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.0/jquery.min.js"></script>

<script>
$(document).ready(function() {
	$('.site-title a').attr('href','https://jellyfish-earthworm-6ny7.squarespace.com/wild-jam-blog/welcome-to-wild-jam');
});
</script>

 

Link to comment
15 hours ago, lisaxhearts said:

Oops. Moved the </style> but it still doesn't want to work.


<style>
  .logo-image img
 {
 content: url("https://static1.squarespace.com/static/5f074ad37551af380fecaa89/t/5f248d886dd338649fdf75be/1596231048241/WildMoonWildJam.flair.v4.transparent-02.png");
 }
</style>

<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.0/jquery.min.js"></script>

<script>
$(document).ready(function() {
	$('.site-title a').attr('href','https://jellyfish-earthworm-6ny7.squarespace.com/wild-jam-blog/welcome-to-wild-jam');
});
</script>

 

Can you share link to page where you inserted the code?

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
9 hours ago, lisaxhearts said:

Use this code

<script>
$(document).ready(function() {
	$('.logo-image a').attr('href','https://jellyfish-earthworm-6ny7.squarespace.com/wild-jam-blog/welcome-to-wild-jam');
});
</script>

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.0/jquery.min.js"></script>
<script>
$(document).ready(function() {
	$('.logo-image a').attr('href','https://jellyfish-earthworm-6ny7.squarespace.com/wild-jam-blog/welcome-to-wild-jam');
});
</script>

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Archived

This topic is now archived and is closed to further replies.


×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.