SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Guru
    Join Date
    Nov 2004
    Location
    calif
    Posts
    723
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How to put text on this image?

    What code is needed so that this image is the bacjkground and so i can put text on it? Thanks

    Code:
    <img src=".../images/box2.gif" border="0" />

  2. #2
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    23,606
    Mentioned
    413 Post(s)
    Tagged
    7 Thread(s)
    The easiest way is to add it via CSS as a background image, rather than place it in your html. Is that an option? Otherwise, you are looking at releative/absolute positioning with z-indexes.

  3. #3
    SitePoint Enthusiast
    Join Date
    Oct 2005
    Location
    Nebraska
    Posts
    54
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    While it's not the best way to do it, in a pinch you could:

    <p style="background: url(../images/box2.gif); width: 50px; height: 50px;">Here's all my text.</p>


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •