Jump to content

Can I change color of text within a text block to highlight certain phrases?

Recommended Posts

  • Replies 3
  • Views 830
  • Created
  • Last Reply
17 hours ago, ElissaV said:

Can you then add links to the different colored words? I can't figure out how to do this without the colors returning to defaults.

 

Try Code Block

<p><a href="https://google.com" class="link1">VISIT</a></p>
<p><a href="https://google.com" class="link2">MISSION</a></p>
<p><a href="https://google.com" class="link3">Exhibitions</a></p>
<p><a href="https://google.com" class="link4">PARTNERSHIPS & PROGRAMME</a></p>
<p><a href="https://google.com" class="link5">MUSEUM STAFF</a></p>
<p><a href="https://google.com" class="link6">PUBLICATIONS</a></p>
<p><a href="https://google.com" class="link7">HISTORY</a></p>
<style>
/* visit link */
.link1 {
color: #c82618;
font-family: pragmatica-extended;
font-size: 35px;
}
.link1:hover {
color: #f1f2f3f4;
}
/* mission link
.link2 {
color: #f15a29;
font-family: pragmatica-extended;
font-size: 35px;
}
.link2:hover {
color: #f7f1f5;
}
/* Exhibitions */
.link3 {
color: #ec671f;
font-family: pragmatica-extended;
font-size: 35px;
}
.link2:hover {
color: #f7f139;
}
</style>

 

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.