Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 7 of 7
  1. #1
    Junior Member
    Join Date
    Sep 2004
    Location
    Chicago
    Posts
    11
    Member #
    7713
    Hello!

    I'm currently working on a website for a client of mine. This is the first time I'm using CSS for positioning, and came across some issues with positioning 3 content boxes(as you'll see in blue below). I have the Container, Header, Nav & footer worked out, I just can't seem to get these boxes aligned right. Basically every time I try something new in coding it, they are scattered about.

    Here is the basic layout of this site...



    I've been playing around w/ the CSS code (and believe me I have a ways to go - still learning) but it would be really helpful and educational for me if someone could please post the proper code that would align these boxes appropriately, or give me some guidance as to what I need to do. I'd post the code I have in there now - but I am at work, not at my home office. I am hoping for a quick response so I can resolve this issue and move on tonite....it's really holding me back! I've done tons of research and still can't seem to get this right!

    I keep going back and forth between the table-based layout I did for the site, and the all CSS layout. Ultimately I'd prefer to go the CSS route, but if there's no solution, for the way I would like this laid out, I'll need to default back to the table-based layout (ick).

    Thank you in advance for your help!

  2.  

  3. #2
    WDF Staff mlseim's Avatar
    Join Date
    Apr 2004
    Location
    Cottage Grove, Minnesota
    Posts
    7,693
    Member #
    5580
    Liked
    717 times
    I kinda have an ongoing example page I keep adding to ...

    See this link for an example: http://catpin.com/pc/

    You can click on the provided link to copy the .css file,
    and use your browser to view the HTML source.

    It might be enough to get you in the right direction.

    ===========

    Keep in mind that if you give your HTML files an extension
    of .php (example: index.php), you can then use "includes"
    to insert text files or other HTML files into the page and do
    dynamic server-side coding to manipulate other things on the
    page. You may not use PHP at first, but if you make the
    extensions .php, it will allow you to do some extra things in
    the future.


  4. #3
    Junior Member branwen's Avatar
    Join Date
    May 2006
    Location
    San Jose, California
    Posts
    7
    Member #
    13185

  5. #4
    Junior Member
    Join Date
    Sep 2007
    Location
    South Africa
    Posts
    14
    Member #
    15813
    hi all,

    sorry to bring this thread back to life after so long, but it's a good post.

    what I would like to ask is this; once you have your css file setup and the site looks they way you want it to visually, how does one reference the boxes in PHP for example?

    in other words, lets say I wanted to put some content into the "leftbox" on the page how would I tell the content that it should display in the "leftbox" when coding with PHP?

    hope my post is not too ambiguous..

    thanks for the great forums..

  6. #5
    Senior Member Shani's Avatar
    Join Date
    Nov 2004
    Posts
    1,140
    Member #
    8171
    PHP Code:
    <div id="leftbox">
    <?php
    //whatever php you want
    ?>
    </div>
    Shani

    I have an eye for detail like you'd never believe.

  7. #6
    Junior Member
    Join Date
    Sep 2007
    Location
    South Africa
    Posts
    14
    Member #
    15813
    thanks!

    am I right in assuming that the box will automatically resize (along with the entire page) should the content be too large for the box itself. I know you can make it scroll but I not a big fan of scroll bars.

    is it possible to have the whole page risize along with the box so that things are still in proportion?

  8. #7
    Senior Member Steax's Avatar
    Join Date
    Dec 2006
    Location
    Bandung, Indonesia
    Posts
    1,207
    Member #
    14572
    That requires Javascript. Generally the box will expand in height to fit whatever is in it, and to modify it with any good calculations will take javascript.
    Note on code: If I give code, please note that it is simply sample code to demonstrate an effect. It is not meant to be used as-is; that is the programmer's job. I am not responsible to give you support or be held liable for anything that happens when using my code.


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 03:17 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com