SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Member
    Join Date
    May 2007
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Beginner CSS questions

    Hello!

    I'am kind of new in the world of HTML and CSS so I was hoping that you guys would help me out a bit.

    First I would like to know if there is a way to empty the space before the HTML list element (<ul><li></li></ul>). When I use list-style-type:none; the bullet is removed before the list text but the space where the bullet was remains in place.

    And the second main problem at the moment is the browser compatibility issue. Can you please tell me what am I doing wrong that IE and FF show so different results. I am using FF to test the code I am writing, but when I tested it with IE I was (to put it mildly) suprised.

    Here are the screenshots of my browser issues and design image, which should give you a picture what the site should look like. Of course I uploaded both of my source code files so you could see where I made a mistake.

    http://zzz.ee/~henry/bugs/

    Thanks in advance,
    Henry
    Last edited by savuss; May 22, 2007 at 22:06.

  2. #2
    SitePoint Guru Dashman's Avatar
    Join Date
    Jan 2006
    Location
    Manchester, UK
    Posts
    627
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi henry,

    Quote Originally Posted by savuss View Post

    First I would like to know if there is a way to empty the space before the HTML list element (<ul><li></li></ul>). When I use list-style-type:none; the bullet is removed before the list text but the space where the bullet was remains in place.
    well, you can remove the padding from the list like so:
    HTML Code:
        ul{
            list-style:none;
            padding:0;
        }
    As for your second question. it looks like its a little more than a imple answer to be honest. Post your code (markup and css) and I'm sure myself or someone else will be able to help you out.

    D

  3. #3
    SitePoint Wizard drhowarddrfine's Avatar
    Join Date
    Aug 2005
    Posts
    3,438
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Learn to write valid code. Go to w3.org and visit the validators for both, html and css, and use them often. You have way too many errors in both for such little markup.

    Also, you have no reason to use transitional and, especially, xhtml. I would stick with html4.01 strict and THEN learn css.

  4. #4
    [Biped] LJK's Avatar
    Join Date
    Jun 2004
    Location
    In My Jammies
    Posts
    761
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi -
    Yup.
    Browsers vary on their interpretations of list positioning.
    Best to add: margin:0 auto; as well to Dashman's...
    test and *then* add specifics to it or the <li>'s for tweaking.

    Have fun,
    El
    F-Fox 2.0 :: WIN :: el design :: US

  5. #5
    SitePoint Wizard bronze trophy Black Max's Avatar
    Join Date
    Apr 2007
    Posts
    4,029
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    I don't have much advice for you, but I can empathize with your situation. You are where I was not too many weeks ago. You're in a good place for help. The folks in this board may seem a bit harsh on rare occasion, but they're invariably helpful, and their advice is always good. I've found that it's worth moving to a strict HTML/CSS coding environment and dealing with the myriad bugs and trash code that will thusly scream for attention. When issues crop up that you find confusing and irritating, just yell for help. (One of these days, I might be competent enough to actually offer some advice myself. The ironic thing is, several years ago I used to write for SitePoint. Don't ask, the articles are still good, for what they are, but they have my real name on them, which I don't use on message boards, and I'm embarrassed that I knew so damn little and had the hubris to actually produce how-to articles for an audience that was far more knowledgeable than myself. And no, I didn't write about CSS. Even I didn't have the hubris that would have required. Hiya, Georgina!)

    You're actually in a far better place than I was. You seem to have a very small Web site that you're developing from scratch (unless there are far more pages than what you provided a link for). I have 100+ very lengthy pages that were crammed to the rafters with garbage code from five years ago; I still have about a dozen pages that have not yet been corrected and boast the ugly, table-filled mess that I used to use. You get to start by doing it right instead of performing an endless job of rewriting and recoding.

    What's interesting for me is that, with the help of Dan, Kraavitz, and so many others on this board, I've managed to totally transform the pages' code while keeping the look and feel of the site almost exactly the same. I like that. Not that my pages are perfect by any means, nor will they ever win any coding or design awards, but they look good to me and perform their function, and for now, I'm happy with that. Now if I could just figure out a way to keep the inordinate amount of content while drastically reducing the size of the pages themselves. No amount of CSS 'trickery' will handle that.


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
  •