Jump to content

Breaking a CSS Site Title into 2 Lines

Go to solution Solved by tuanphan,

Recommended Posts

Hello, I am looking to adjust the site title in the header so that it drops down a line, and doesn't push the site logo over. I added some CSS code to display "the site name" (though it is just a text line) as well as the uploaded logo image.

The site currently looks like this:

image.thumb.png.3b6ad867458ae6c921093cf2d459be91.png

 

But i would like to drop the word Foundation down a line to look like this:

image.png.7f121f99f02daac08e3d9b7e4eb4850f.png

 

Is there a way I can do this in CSS?

 

Here is the code I have to add the text alongside the logo:

 

.header-title-logo a:before {
    content: "Chris Eckert Foundation";
    display: inline-block;
    font-size: 25px;
    font-family: calibri;
    color: black;
    text-align: center;
    vertical-align:middle;
    font-weight:900;
    padding-left: 10px;
}
.header-title-logo img {
    vertical-align: middle;
}

 

 

 

 

Thanks for any assistance you can provide.

Edited by Jefffav
Link to comment
  • Replies 2
  • Views 341
  • Created
  • Last Reply

Top Posters In This Topic

  • Solution

Change to this code. If it doesn't work, please share link to your site, we can test code easier

.header-title-logo a:before {
    content: "Chris Eckert \A Foundation";
	white-space: pre-wrap;
    display: inline-block;
    font-size: 25px;
    font-family: calibri;
    color: black;
    text-align: center;
    vertical-align:middle;
    font-weight:900;
    padding-left: 10px;
}
.header-title-logo img {
    vertical-align: middle;
}

 

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

Create an account or sign in to comment

You need to be a member in order to leave a comment


×
×
  • 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.