开发者

CSS blogspot background positioning help

i'm trying my hands on coding a skin for blogspot.com i basically got everything else done except for one issue which is a part of my design.

Beside the title of the blog, i've design it such that there will be an image floating right next to the title of the blog. That would be easy if i were to use add in a tag into the widget section, but if i were to share this among people (where they will also have different blog name which result in different length) so the image will move according to the title's length. I'm having problem with this.

I've no idea how i should attempt on this as i can't use php on blogspot =/

To better understand what i said, 开发者_StackOverflow中文版here's an example of what i meant http://i558.photobucket.com/albums/ss23/crayscrays/randomfonthelp.jpg


Since it's applied as a background image, you can set the value as "right", to make it go to the right side of the element.

Say, for example, this is your markup:

<h1>This is a blog post</h1>

Your CSS would look something like this:

h1 { 
  background: transparent url(myimage.jpg) no-repeat right center; 
  padding-right: [widthOfImage]px;
}

That would align the image to the right side of the text.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜