The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Centering text on a image

View previous topic View next topic Go down

Centering text on a image

Post by angel_of_night on May 10th 2012, 12:59 am

Hello.
Is there any HTML code that centers the text like this:



I saw some forums doing this, but not sure about this one.
Thank you

angel_of_night
Forumember

Female Posts : 565
Reputation : 10
Language : portuguese

Back to top Go down

Re: Centering text on a image

Post by Guest on May 10th 2012, 6:11 am

Hi!

If tht's text, add to CSS Stylesheet:
Code:
a.mainmenu[href="/profile?mode=editprofile"]{
  position: relative;
  bottom: 5px;
}

a.mainmenu[href="/profile?mode=editprofile"] img{
  position: relative;
  top: 10px;
}
The first code move the text from bottom to top with 5px;
The second code move the image from top to bottom with 10px.
So please edit your values so how will be better.

Guest
Guest


Back to top Go down

Re: Centering text on a image

Post by angel_of_night on May 10th 2012, 6:17 am

Coddy wrote:Hi!

If tht's text, add to CSS Stylesheet:
Code:
a.mainmenu[href="/profile?mode=editprofile"]{
  position: relative;
  bottom: 5px;
}

a.mainmenu[href="/profile?mode=editprofile"] img{
  position: relative;
  top: 10px;
}
The first code move the text from bottom to top with 5px;
The second code move the image from top to bottom with 10px.
So please edit your values so how will be better.

Sorry.. I didn't really understand Confused
Can you give a real example?

angel_of_night
Forumember

Female Posts : 565
Reputation : 10
Language : portuguese

Back to top Go down

Re: Centering text on a image

Post by Guest on May 10th 2012, 6:20 am

I thought to something else:
Code:
a.mainmenu[href="/profile?mode=editprofile"]{
  position: relative;
  bottom: 5px;
}

a.mainmenu[href="/profile?mode=editprofile"] img{
  position: relative;
  bottom: 0px !important;
}
Just add this code into CSS Stylesheet.

Guest
Guest


Back to top Go down

Re: Centering text on a image

Post by angel_of_night on May 10th 2012, 6:27 am

Doesn't work. I want a HTML to work on topics only.

angel_of_night
Forumember

Female Posts : 565
Reputation : 10
Language : portuguese

Back to top Go down

Re: Centering text on a image

Post by LGforum on May 10th 2012, 11:37 pm

You need to use the CSS property 'line-height' Wink

LGforum
Hyperactive

Male Posts : 2260
Reputation : 258
Language : English
Location : UK

http://www.avacweb.com/

Back to top Go down

Re: Centering text on a image

Post by angel_of_night on May 12th 2012, 12:30 am

@LGforum wrote:You need to use the CSS property 'line-height' Wink
Sorry I didn't understand...

angel_of_night
Forumember

Female Posts : 565
Reputation : 10
Language : portuguese

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum