CSS style linkposts (Squarespace)


Regarding that last post, here’s a solution for one of the complaints. This allows you to apply a CSS class to every linkpost on your Squarespace 6 site. Just add the below to your header on the Code Injection page in settings.

Download the code here

Once you’ve done that, you can edit custom CSS and something like this will allow you to style link posts:

.linkpost {color:#2f7cda;}

NOTE: The original solution I had here was slightly different — this is a solution that should work on all templates, based on the fact that Squarespace appends an arrow to link posts (that’s the span in the title that the above code finds.) On the off-chance this changes, the important thing is to find something unique about link-posts and substitute that instead of .post-title span.

If this doesn’t work, you could always give your link posts a “link” category and then style on .category-link. This solution just cuts out a little of the extra effort.