
My first thought was "Damn I didn't save the image with transparency." So I close the preview window and notice that it was transparent in the edit window. I re-preview and sure enough the image background issue is back. So then I was all "It's not me, ITS YOU!". Turns out the issue wasn't the image transparency, but the Blogger Theme and the CSS behind it. Here's the same image with the background "issue".

I pop open the Blogger>Template>Customize tool (Orange "Customize" button). Then proceed to Advanced>Images as well as Post Background. Seen in the image below.
There it is... under "Images". "I've got you now" I say in my head. I change the "Background Color" to "transparent" via the drop down selector. Hit "Apply to Blog", re-preview and all is fixed.
CAVEAT
Now this may not work for other folks using different themes and/or custom/customized themes. The other way to do this is to insert your image(s) and toggle to the raw HTML edit mode in the Post Editor and add a style tag to the image with the "background" property set to the color of the background of your blog's post background. You can do this using the following code/example.
<img src="http://blah.com/Icon.png" style="background: #222222;" />
Take note of the following part style="background: #222222;" as this is the part your going to want to change in your image to the correct hex color of your background. You can also add more style tag properties here to do other stuff as well. I won't go too far into this, you can "google" this yourself, but here are the properties I set on the first image in this post to get things to line up properly.
style="border: 0; float: left; margin-bottom: 1em; margin-right: 1em;"
No comments:
Post a Comment