Site name is persistent! How to remove and replace with logo?

Permalink 2 users found helpful
I am currently working in the TerraFirma2 theme, but my question applies regardless...

I have gone repeatedly into dashboard and sitewide settings to change the site name, but when I clear it out and try to save it always defaults to "concrete5". I do not want this, or any other particular name displayed. Is there a way around this?

Is there a way I can replace it with a logo I've designed elsewhere?

Thanks for any help, I've done some searching on the subject but going into settings isn't resolving my issues.

writewordproductions
 
dg1 replied on at Permalink Reply
To replace the name with your logo, do the following. Go into the dashboard and click on the scrapbook. Then click on "Global Scrapbook". You should see an entry in the global scrapbook for My_Site_Name. Click on the edit link for this entry and it will bring up an editor where you can add in your logo image. That should do it.
writewordproductions replied on at Permalink Reply
writewordproductions
Thanks for your help.

I have seen the comments about modifying this in scrapbook, but I do not have a "my_site_name" entry under Global. There are no items in there, and I don't see an option for site name when I click to edit blocks for the scrapbook.

Can you shed any light on this, too?

Thanks again!
dg1 replied on at Permalink Reply
I'm not sure why it would be missing from your global scrapbook but it is easy to add it back in. Click on the "Add Block to Scrapbook" button at the top and add in a content block. After you save it, rename it to My_Site_Name. Most themes have code to grab this so the name is important.

e.g. This is from the dark chocolate theme header:

$block = Block::getByName('My_Site_Name');
if( $block && $block->bID ) $block->display();
else echo SITE;
writewordproductions replied on at Permalink Reply
writewordproductions
Ok, I seem to have successfully created My_Site_Name in Global Scrapbook and have selected my logo image and saved it.

However, nothing is happening to change the site name on my website. I can't edit that site name block, of course, so not sure what to do now.
writewordproductions replied on at Permalink Reply
writewordproductions
Well, damn. I had a hunch and tested by switching to a default theme (dark chocolate), and my logo does load.

Unfortunately, it still isn't working on TerraFirma2, which is disappointing.
ThemeGuru replied on at Permalink Reply
ThemeGuru
Cache error?

Had a lot of those recently.. Ugh...
CWSpear replied on at Permalink Reply
CWSpear
If the theme's files don't have
$block = Block::getByName('My_Site_Name');
if( $block && $block->bID ) $block->display();
else echo SITE;

in them (typically in elements/header.php) I don't think the method they are describing will work.

You'll need to add that to the proper place in the code, or hard code in your logo or something. I'll try downloading the TerraFirma2 theme and see if I can figure out the problem for ya.
writewordproductions replied on at Permalink Reply
writewordproductions
Thanks so much, Volkner! Please let me know what you're able to figure out.

I generally learn things pretty quickly but I'm a complete n00b when it comes to writing code, so I'll need a little hand-holding at first, haha.
CWSpear replied on at Permalink Reply
CWSpear
Ok, my theory was correct! That code was NOT in the header file. Here's an edited header file. Do you need help replacing the old header.php file? If so, I can walk you through that. You'll need FTP access to your site. Depending on how you installed the theme, the header.php file is probably located in
/packages/theme_terrafirma2/themes/terrafirma2/elements/header.php


edit: argh, it won't let me upload a .php file, so I changed it to .txt. Just change the extension to .php. It needs to replace the header.php file described above. Make sure you CHANGE the extension, (sometimes if you're not careful, you'll end up with the file header.php.txt)
writewordproductions replied on at Permalink Reply
writewordproductions
I installed it through Marketplace.

And yes, would you mind walking me through? I'm poking around in dashboard and not seeing where to alter this stuff...

Thank you again!
CWSpear replied on at Permalink Reply
CWSpear
I don't know of a way of doing it through the dashboard. I don't think you can. To edit the source code, you'll use FTP (File Transfer Protocol) to get in.

Ok, before I know where to go next... Who installed your concrete5 site? Who are you hosting with? Do you own this site?
writewordproductions replied on at Permalink Reply
writewordproductions
I installed it, I do own the site, and I am hosting through MacHighway.com
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
Ok, good. So you should know how to FTP in?

Once you get to your document root, go to:
/packages/theme_terrafirma2/themes/terrafirma2/elements/
In that elements folder, there are two files. header.php and footer.php. Either replace that header.php with the one I have attached (use this one because I forgot to make it a link in the previous one) or else find and replace the line
<h1><a href="<?php  print DIR_REL; ?>/"><?php  print SITE; ?></a></h1>

with
<h1>
   <a href="<?php  print DIR_REL; ?>/">
   <?php $block = Block::getByName('My_Site_Name');
   if( $block && $block->bID ) $block->display();
   else echo SITE; ?>
   </a>
</h1>

Then it's just a matter of doing that scrapbook thingy like the way it worked in Dark Chocolate.

Let me know if it worked!!
dg1 replied on at Permalink Reply
I downloaded TerraFirma2 too and saw that it is only echoing SITE but it looks like Volkner beat me to it. I thought it was a standard convention for themes to include the code like the chocolate theme where you have a block name My_Site_Name. Fortunately, it is easy enough to add.
writewordproductions replied on at Permalink Reply
writewordproductions
I am honestly not sure how to view from FTP, can you get me started there?
CWSpear replied on at Permalink Best Answer Reply
CWSpear
Ok, I see that MacHighway.com might have let you install concrete5 through them. My previous instructions still apply, but may not have made sense if you didn't manually (via FTP) install your site.

Here's super detailed instructions. Still a little confusing. I'd do it for you if you wanna give me your domain name and FTP credentials, but I wouldn't general advise that. Cuz you don't know who I am and I could mess with your site bad. Definitely don't post them on the forum.

So either you FTP in or maybe MacHighway.com has a file manager for your website. You should ask MacHighway.com for FTP credentials (you need a username and password. They may have emailed it to you when you first signed up).

Then you need an FTP program. If you're on a PC, try FileZilla. If you're on a Mac, try Cyberduck.

There are a bunch of advanced options, but just fill in your server name which is yourdomainname.com. Use the above mentioned username and password. Leave everything else as the default (port:21, root:empty).

Your document root is in a different folder depending on the server setup. Typically /public_html or /httpdocs.

Eventually, you'll find a folder that contains a bunch of folders and files, amongst which will be "blocks," "config," "concrete" and so on. That's your document root.

So then go to packages then to theme_terrafirma2/themes/terrafirma2/elements/

Then follow my earlier directions. It can be overwhelming... Hope that helps.
writewordproductions replied on at Permalink Reply
writewordproductions
Thanks! I'm on a Mac so I'm rolling with Cyberduck per suggestion. I'll try to wade my way through this and holler as needed for help. ;)
writewordproductions replied on at Permalink Reply
writewordproductions
Alright, I'm to the point where I have footer.php and header.php in front of me.

When I try to edit header, it just opens up a black screen in textedit and I have no actual content that I can alter. What to do from here?
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
Um... weird. It should show up in TextEdit. It's not a super big file, and it should appear as plain text. Hmm...

Well, plan B! You can just replace it with the file I attached (the 2nd time... um, I'll reattach it now).

So because it won't let me attach a .php file, I'm uploading it as a .txt file. Remember to change the extension to .php and replace the header.php file there with my header.php file.

That should be all that's to it! Simple, right? Haha!!
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
A lot of work for a logo, eh?

I found some info on MacHighway:

-- From MacHighway --

In the "Server" field, type in your host server address listed in your email "MacHighway New Account Information"

In the "Username" and "Password" fields, type your FTP username and password as listed in your email "MacHighway New Account Information"

-- End MacHighway --

It also confirms that your document root is in /public_html

I've attached an image of kinda what it should look like in Cyberduck. That gets you to the document root. Then you go to /packages/theme_terrafirma etc etc.
writewordproductions replied on at Permalink Reply
writewordproductions
I made it successfully through all of that. I found the root and all the files to get me to where I can select the header and footer. I'm just having trouble opening the header to where I can edit it. I get a blank black screen with no content when I click to edit.
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
Um... weird. It should show up in TextEdit. It's not a super big file, and it should appear as plain text. Hmm...

Well, plan B! You can just replace it with the file I attached (the 2nd time... um, I'll reattach it now).

So because it won't let me attach a .php file, I'm uploading it as a .txt file. Remember to change the extension to .php and replace the header.php file there with my header.php file.

That should be all that's to it! Simple, right? Haha!!
writewordproductions replied on at Permalink Reply
writewordproductions
You're pretty much my favorite person ever right now, haha.

Ok, how do change the extension on your file to .php? If I try to open it I'm redirected to an error page since it's a txt.xhtml file.

I swear I should be done bugging you shortly if this all pans out as planed!
CWSpear replied on at Permalink Reply
CWSpear
It's okay!

So there can be issues with hidden extensions...

Right click on the header.txt file in Finder and choose "Get Info." Under the section "Name & Extension:" it will have the full name and extension. You want that field to be exactly
header.php
CWSpear replied on at Permalink Reply
CWSpear
Ok... weirdly enough, that didn't work when I tried it. I've done it before. Try unchecking "hide extension" and just editing the file to header.php. Or try editing the name in Cyberduck because it's more literal.
writewordproductions replied on at Permalink Reply
writewordproductions
I was able to switch it through Finder. I appear to have successfully replaced header.php! Woohoo, now for the defining moment.... lol.
writewordproductions replied on at Permalink Reply
writewordproductions
Ahh! You're brilliant, it seems to be working.

Mostly. It may be my logo needing proper sizing, it's coming up lopsided and out of place in a way that I'm unable to move like the other blocks.

Peek at www.www.writewordproductions.com... to see what I mean.
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
Try using this attached image.
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
If you want something like the screenshot attached, you'll need some programmer skills. You'll need to edit some CSS and stuff.

I'm available for hire =)
writewordproductions replied on at Permalink Reply
writewordproductions
That's better! It's small, but it's in the box. Any way to find out the dimensions of that orange space for an accurate fit?
writewordproductions replied on at Permalink Reply
writewordproductions
Oops, I see you beat me to the punch. And yes, that is what I am going for....

Unfortunately, "broke" doesn't even begin to accurately describe my financial situation, so I'm a DIY'er by both nature and necessity.
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
Without editing the CSS, the best you could do is to get it to fit in the light blue highlighted box in this screenshot.

It's because the person that made this theme put padding around that area (the dark purple highlight part), so without editing the CSS, you can't get into the purple...
writewordproductions replied on at Permalink Reply
writewordproductions
Ah ha... Care to point me in the direction of a helpful "CSS for beginners" guide, by chance?

I REALLY appreciate all of your help tonight, seriously. You're very knowledgeable and your explanations are concise and easily followed. Thank you much!
CWSpear replied on at Permalink Reply 1 Attachment
CWSpear
Um, I learned CSS the hard way (trial and error basically!), so I can't give you a better answer than Google :-S Sorry.

I will give you a tip on the logo.

Go to main.css in your theme directory and find where it says "#logo h1"

Replace
#logo h1 {
   padding: 137px 0 0 50px;
   letter-spacing: -2px;
   /* customize_header_logo */ font: normal normal normal 34px "Trebuchet MS",Arial,Helvetica,sans-serif; /* customize_header_logo */
   /* customize_header_logo */ color: #FFFFFF; /* customize_header_logo */
}

with
#logo h1 {
    left: -21px;
    letter-spacing: -2px;
    padding-top: 96px;
    position: relative;
}

and use the image attached.

It's a little quick and dirty, but it SHOULD work... no guarantees though!

And I'm off to bed, so if Cyberduck won't open that main.css file, I'm afraid I won't be any more help tonight. It should open it no problem with TextEdit. Or try downloading it to your local directory, editing it and uploading it again.
writewordproductions replied on at Permalink Reply
writewordproductions
Great, I'll try it out! Already started my Googling efforts on CSS basics, one step at a time with this game for sure.

Thank you again!
writewordproductions replied on at Permalink Reply
writewordproductions
Interesting results.... Check it out tomorrow if you have a second.