Go Back   Webmaster Forum > Development > Web Development > HTML and CSS
REMOVE the ads below !
Reply
 
LinkBack Thread Tools
  # 1 (permalink)
Old
Newbie
Posts: 23
Join Date: Jun 2008
iTrader: (0)
My HTML Problems - 07-01-2008

Hi i'm writing a site, and i came to a problem that i can't figure out.

heres the document so far
XPHost.info - Your XP Homebase

now the xp image is located there where it is, in a floating div,
i'm wondering is it possible to write something over that floating div and how to do that.

heres the link to the css file.
http://zuly.bestfreewebhost.info/stil/syle.css
Reply With Quote
  # 2 (permalink)
Old
The Computer Addict !
Posts: 1,996
Join Date: Feb 2007
iTrader: (0)
Location: Bhopal (MP, India)
07-01-2008

Use the XP Logo as the DIV's background, and the write the text inside the DIV as usual.

Currently you have this markup in your HTML file :

HTML Code:
<div class="float"><img src="slike/xp-logo.jpg"></div>
Change it to :

HTML Code:
<div class="float xp-bg">
   Write your text here.
</div>
And in the CSS file, add this rule :

Code:
.xp-bg {
   background: url("../slike/xp-logo.jpg") top left no-repeat;
}
Reply With Quote
  # 3 (permalink)
Old
Newbie
Posts: 23
Join Date: Jun 2008
iTrader: (0)
07-01-2008

I'm sorry but i explained it wrong, so i'm drawing it now.
this will be a lot easier, for the both of us.


So you see i actually wanted to write something above the picture(sorry once more, i'm learning on this template), and then i want to write something beside it and underneath it. Is there some magical rule that allows this?
Thanks.
Reply With Quote
  # 4 (permalink)
Old
The Computer Addict !
Posts: 1,996
Join Date: Feb 2007
iTrader: (0)
Location: Bhopal (MP, India)
07-03-2008

For that layout use this :

HTML Code:
<div> <strong>Some Title That can go to here</strong> <br clear="all" /> <div class="float-left"> <img src="http://zuly.bestfreewebhost.info/slike/xp-logo.jpg" /> </div>

   Some text that is for that title ... <br />
   blah ... blah ... blah. Some more blah.<br /><br />

   Some text that is for that title ... <br />
   blah ... blah ... blah. Some more blah.<br />
   Some text that is for that title ... <br />
   blah ... blah ... blah. Some more blah.<br /><br />

   Some text that is for that title ... <br />
   blah ... blah ... blah. Some more blah.

</div>
Code:
.float-left {
   float: left;
   padding: 5px 10px 10px 0px;
}
Reply With Quote
  # 5 (permalink)
Old
Newbie
Posts: 23
Join Date: Jun 2008
iTrader: (0)
07-03-2008

Thanks, a lot for this, it is exactly what i wanted i tried witting above the image without this code and text simply moved the picture, to the right.
Can you tell me what makes the title stick to the top now?
Is it this
HTML Code:
<br clear="all" />
Reply With Quote
  # 6 (permalink)
Old
The Computer Addict !
Posts: 1,996
Join Date: Feb 2007
iTrader: (0)
Location: Bhopal (MP, India)
07-04-2008

Yes. That line break ensures that the image is placed below the text preceding it.

Reply With Quote
  # 7 (permalink)
Old
Newbie
Posts: 23
Join Date: Jun 2008
iTrader: (0)
07-06-2008

Ok, sorry for the delay in answering i was busy thanks again.
Reply With Quote
Reply


Thread Tools



Advertise Here for just $6 per month

vBulletin®, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd. | SEO by vBSEO | Skin developed by vBStyles.com