FRIHOSTFORUMSFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

Need Help with this CSS/HTML Thing.

 


Runescapetown
Ok im making a Div layout and a part isnt working ( the white bit)
http://www.rs2helpguide.frih.net/test.php/

It doesnt want to go to the middle of the page where the rest of the other stuff. is

Here is the CSS Coding.

Code:
/** TOP PICTURE */
#topback {
        width: px;
   height: 191px;
background-image: url('http://www.rs2helpguide.frih.net/images/top.PNG');
   background-position: top center;
   background-repeat: no-repeat;
}

/** UNDER THE TOP */
#undertop {
        width: px;
   height: 28px;
background-image: url('http://www.rs2helpguide.frih.net/images/undertop.PNG');
   background-position: top center;
   background-repeat: no-repeat;
}
/** THE SIDES-LONG */
#sides-long {
        width: 928px;
   height: 50px;
background-image: url('http://www.rs2helpguide.frih.net/images/sides-long.PNG');
   background-position: top right;
   background-repeat: repeat;
}
/** SOMESH*T */
#maincontent {
   font-size:1.0em;
   padding:0px 5px 0px 0px;
   width:550px;
   border-right:1px solid #ff0066;
   float:left;



What will make the White PArt go to the middle where the rest of the stuff are please help.
wumingsden
preview: http://mezmorizing.net/test/runescapetown/index.php

quickfix:

open test.php...

Find:

Code:
<div id="sides-long"><center>testing
</div>


Replace with

Code:
<center>
<div id="sides-long"><center>testing
</div>
</center>


Your center tags are nestled incorrectly too ... shown in red bold ...

Quote:
<body bgcolor="green">
<link rel="stylesheet" href="style.css" type="text/css">
<div id="topback">
</div>

<div id="undertop">
</div>
<div id="sides-long"><center>testing
</div>
<div id="maincontent">
</div>
<center>
testing


Two open center tags, no closing tags.
Wilio
Well I only added the px value to each and then add a left margin of 50px
Code:

/** TOP PICTURE */
#topback {
        width: 928px;
   height: 191px;
background-image: url('http://www.rs2helpguide.frih.net/images/top.PNG');
   background-position: top center;
   margin-left: 50px;
   background-repeat: no-repeat;
}

/** UNDER THE TOP */
#undertop {
        width: 928px;
   height: 28px;
background-image: url('http://www.rs2helpguide.frih.net/images/undertop.PNG');
   background-position: top right;
   background-repeat: no-repeat;
   margin-left: 50px;
}
/** THE SIDES-LONG */
#sides-long {
        width: 928px;
   height: 50px;
background-image: url('http://www.rs2helpguide.frih.net/images/sides-long.PNG');
   background-position: top center;
   background-repeat: repeat;
   margin-left: 50px;
}
/** SOMESH*T */
#maincontent {
   font-size:1.0em;
   padding:0px 5px 0px 0px;
   width:550px;
   border-right:1px solid #ff0066;
   float:left;
   margin-left: 50px;
}
Runescapetown
Thanks wumingsden you helped me with so many things.

Thanks! Very Happy
wumingsden
Runescapetown wrote:
Thanks wumingsden you helped me with so many things.

Thanks! Very Happy


Your welcome. Another user gives another method above which you may want to use.

Can I delete the files from my account or is there anything thing else you need help with?

if not i'll also lock this topic, so i'll be awaiting your reply.
Runescapetown
Ye you can delet the account thing. And lock this forum.

Thanks again.
wumingsden
will start working on the latest problem which you sent me through PM in an hour or so, as i'm a bit busy. solution will be posted here (if i find it)
wumingsden
This is currently your source code, the bit in highlighted bold red is causing the problem. By simply removing it solves the problem:

Quote:
<body bgcolor="green">
<link rel="stylesheet" href="style.css" type="text/css">
<div id="topback">
</div>

<div id="undertop">
</div>
<center>
<div id="sides-long">testingdsfdsfsdfnk mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p> mj<p>

</div>
</center>

<center>
<div id="sides-bottom">
</div>



I recommend instead of using <p> use <br /> instead.

I also recommend creating a folder named test in your public_html directory. You should then move the file named test.php in the test folder. Then rename the test.php file to index.php. Then also move the style.css file to the test folder. Much simplier, and it seperates test files too. Also, to visit the style file you don't have to go to yoursite.com/test.php/style.css as it will now be yoursite.com/test/style.css

Edit: also, the page doesn't have the simpliest of tags which include the <head>, <body>, <title>, etc, tags. This is ok if your working on a test page like you are now, or if your going to include them via php.
Reply to topic    Frihost Forum Index -> Scripting -> Html, CSS and Javascript

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.