Simple CSS question?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Michael Stemper

    #16
    Re: Simple CSS question?

    In article <ssf4d.14656$54 .220486@typhoon .sonic.net>, Bob writes:
    [color=blue]
    >I am trying create a list of companies consisting of several one-liners in
    >the form of : company name, address, phone, description, etc. I want the
    >text to have no margins and no space between lines, but I want the first
    >line bold. And, I want a space between companies such as:
    >
    >Name:_________ . (bold)
    >Address:______ _______.
    >Phone:________ __.
    >Email:________ ________.
    >Website:______ ____________.
    >Description:__ _______________ ____.[/color]

    [snip]

    My question's really more towards the other respondents. Why wouldn't the
    correct markup be a definition list per company? It seems semantically
    correct: you're defining the name, address, etc. for each company.

    --
    Michael F. Stemper
    #include <Standard_Discl aimer>
    No animals were harmed in the composition of this message.

    Comment

    • Neal

      #17
      Re: Simple CSS question?

      On Wed, 22 Sep 2004 11:40:07 -0500, Michael Stemper
      <mstemper@sieme ns-emis.com> wrote:
      [color=blue]
      > In article <ssf4d.14656$54 .220486@typhoon .sonic.net>, Bob writes:[color=green]
      >> Name:_________. (bold)
      >> Address:_______ ______.
      >> Phone:_________ _.
      >> Email:_________ _______.
      >> Website:_______ ___________.
      >> Description:___ _______________ ___.[/color]
      > My question's really more towards the other respondents. Why wouldn't the
      > correct markup be a definition list per company? It seems semantically
      > correct: you're defining the name, address, etc. for each company.[/color]

      Hmm... I suppose it's arguable, but isn't "Name" the definition of the
      term "Michael Stemper", not the other way around?

      There is a one-to-one correspondence, but that isn't enough to merit dl
      markup, I don't think. A table would be appropriate markup here, though,
      as you're organizing content which is related by row and by column.

      Comment

      • Bob

        #18
        Re: Simple CSS question?


        "Neal" <neal413@yahoo. com> wrote in message
        news:opseql45ms 6v6656@news.ind ividual.net...[color=blue]
        > On Wed, 22 Sep 2004 11:40:07 -0500, Michael Stemper
        > <mstemper@sieme ns-emis.com> wrote:
        >[color=green]
        > > In article <ssf4d.14656$54 .220486@typhoon .sonic.net>, Bob writes:[color=darkred]
        > >> Name:_________. (bold)
        > >> Address:_______ ______.
        > >> Phone:_________ _.
        > >> Email:_________ _______.
        > >> Website:_______ ___________.
        > >> Description:___ _______________ ___.[/color]
        > > My question's really more towards the other respondents. Why wouldn't[/color][/color]
        the[color=blue][color=green]
        > > correct markup be a definition list per company? It seems semantically
        > > correct: you're defining the name, address, etc. for each company.[/color]
        >
        > Hmm... I suppose it's arguable, but isn't "Name" the definition of the
        > term "Michael Stemper", not the other way around?
        >
        > There is a one-to-one correspondence, but that isn't enough to merit dl
        > markup, I don't think. A table would be appropriate markup here, though,
        > as you're organizing content which is related by row and by column.[/color]

        Hi Again Neil,

        But are tables appropriate when you only have one column?

        Also, I actually have three different formats that are similar in layout but
        different in content. Currently, they are all done with simple markup using
        <p>'s and <br>'s. You can see the three types at:





        Do you think that all three of these would best be done with plain markup,
        tables, or CSS?

        Thanks a lot,

        Bob


        Comment

        • Neal

          #19
          Re: Simple CSS question?

          On Wed, 22 Sep 2004 16:54:55 GMT, wrote:
          [color=blue]
          > Do you think that all three of these would best be done with plain
          > markup,
          > tables, or CSS?[/color]

          http://www.usernomics.com/ergonomic-products-audio.html - nested unordered
          lists. Each entry is a list of info, and the whole section is a list of
          lists. Modify presentation with CSS. Use whatever heading makes sense in
          the page design.

          <ul>
          <li><h?>Andre a Electronics Corporation</h?>
          <ul>
          <li>Long Island City, NY, 11101</li>
          <li>Phone: (718) 729-8500</li>
          etc...
          </ul>
          </li>
          <li><h?>The next one</h?>
          <ul>
          <li>Listed information</li>
          etc...

          http://www.usernomics.com/human-fact...s-design1.html - similar.

          <ul>
          <li><h?>An Introduction to Usability</h?>
          <ul>
          <li>by Patrick W. Jordan</li>
          <li>February 1999</li>
          </ul>
          <p>Introducti on to the topic of usability...</p>
          </li>
          <li><h?>The next title</h?>
          <ul>
          <li>Etc.</li>
          ....

          http://www.usernomics.com/ergonomics-news.html - no list info here as far
          as I can see, though list markup could be applied with each li containing
          each blurb.

          <h?>Risky Business: Firms Can Reduce Human Errors Through Proactive Use of
          Risk Analysis</h?>
          <p>It should come as no surprise ... and indicates how they can be used to
          assess business-centric risks.</p>
          <cite>(full article): Medical News IT Tech Wire, Setptember 20, 2004</cite>

          And there are other possible interpretations for all of these, too.

          Comment

          • Beauregard T. Shagnasty

            #20
            Re: Simple CSS question?

            Quoth the raven Neal:
            [color=blue]
            > On Wed, 22 Sep 2004 16:02:48 GMT, Beauregard T. Shagnasty
            > <a.nony.mous@ex ample.invalid> wrote:
            >[color=green]
            >> What about using the address element?
            >>
            >> <address>
            >> Name: <strong>ABC Company</strong><br>
            >> Address: 321 Main Street<br>
            >> Phone: 01 1 123 456<br>
            >> Email: xyz@example.com<br>
            >> Website: http://xyz.example.com <br>
            >> Description: Sells computers
            >> </address>[/color]
            >
            >
            > Address is for marking up a page's author contact info. If that's what's
            > being done, OK.[/color]

            Ok, but aren't his names and addresses essentially contact
            information? It sounds semantically correct to me...

            --
            -bts
            -This space intentionally left blank.

            Comment

            • Neal

              #21
              Re: Simple CSS question?

              On Wed, 22 Sep 2004 17:24:02 GMT, Beauregard T. Shagnasty
              <a.nony.mous@ex ample.invalid> wrote:
              [color=blue]
              > Quoth the raven Neal:[color=green]
              >> Address is for marking up a page's author contact info. If that's
              >> what's being done, OK.[/color]
              >
              > Ok, but aren't his names and addresses essentially contact information?
              > It sounds semantically correct to me...[/color]



              "The ADDRESS element may be used by authors to supply contact information
              for a document or a major part of a document such as a form. This element
              often appears at the beginning or end of a document."

              For historical purposes, http://www.w3.org/TR/REC-html32#address

              "The ADDRESS element requires start and end tags, and specifies
              information such as authorship and contact details for the current
              document. User agents should render the content with paragraph-breaks
              before and after. Note that the content is restricted to paragraphs, plain
              text and text-like elements as defined by the %text entity."

              and http://www.ietf.org/rfc/rfc1866.txt

              "5.5.3. Address: ADDRESS

              The <ADDRESS> element contains such information as address, signature
              and authorship, often at the beginning or end of the body of a
              document."

              So in all versions of HTML, the address element refers to the contact
              information of the author of the document we are reading. It is not
              appropriate markup for "any" address.

              Comment

              • Beauregard T. Shagnasty

                #22
                Re: Simple CSS question?

                Quoth the raven Neal:
                [color=blue]
                > So in all versions of HTML, the address element refers to the
                > contact information of the author of the document we are reading.
                > It is not appropriate markup for "any" address.[/color]

                Yes, I did read all that. It just seems easier to mark up an address
                with an address element. <g>

                Thanks for your answers.
                --
                -bts
                -This space intentionally left blank.

                Comment

                • Bob

                  #23
                  Re: Simple CSS question?


                  "Neal" <neal413@yahoo. com> wrote in message
                  news:opseqneny0 6v6656@news.ind ividual.net...[color=blue]
                  > On Wed, 22 Sep 2004 16:54:55 GMT, wrote:
                  >[color=green]
                  > > Do you think that all three of these would best be done with plain
                  > > markup,
                  > > tables, or CSS?[/color]
                  >
                  > http://www.usernomics.com/ergonomic-products-audio.html - nested unordered
                  > lists. Each entry is a list of info, and the whole section is a list of
                  > lists. Modify presentation with CSS. Use whatever heading makes sense in
                  > the page design.
                  >
                  > <ul>
                  > <li><h?>Andre a Electronics Corporation</h?>
                  > <ul>
                  > <li>Long Island City, NY, 11101</li>
                  > <li>Phone: (718) 729-8500</li>
                  > etc...
                  > </ul>
                  > </li>
                  > <li><h?>The next one</h?>
                  > <ul>
                  > <li>Listed information</li>
                  > etc...
                  >
                  > http://www.usernomics.com/human-fact...s-design1.html - similar.
                  >
                  > <ul>
                  > <li><h?>An Introduction to Usability</h?>
                  > <ul>
                  > <li>by Patrick W. Jordan</li>
                  > <li>February 1999</li>
                  > </ul>
                  > <p>Introducti on to the topic of usability...</p>
                  > </li>
                  > <li><h?>The next title</h?>
                  > <ul>
                  > <li>Etc.</li>
                  > ...
                  >
                  > http://www.usernomics.com/ergonomics-news.html - no list info here as far
                  > as I can see, though list markup could be applied with each li containing
                  > each blurb.
                  >
                  > <h?>Risky Business: Firms Can Reduce Human Errors Through Proactive Use of
                  > Risk Analysis</h?>
                  > <p>It should come as no surprise ... and indicates how they can be used to
                  > assess business-centric risks.</p>
                  > <cite>(full article): Medical News IT Tech Wire, Setptember 20,[/color]
                  2004</cite>[color=blue]
                  >
                  > And there are other possible interpretations for all of these, too.
                  >[/color]

                  Hello Neal,

                  I gave it a shot but it did not quite work quite right for me. I placed a
                  sample of each of the three formats (Products, News, and Books) on the same
                  page at www.usernomics.com/testsite/test.html .


                  I tried creating a new <li> category because the <li> that I am currently
                  using elsewhere has a bullet and is indented. So I wanted to get one that
                  has no bullet and was left justified. I used this expression but it did not
                  work:

                  ..single li{
                  text-align: left;
                  margin: 0; padding: 0;
                  }

                  ..single{
                  list-style: none;
                  }

                  As you can see, I am not CSS proficient and am not sure how to create single
                  lines of <li>'s without the bullet and indent. Also, the Book information
                  did not wrap around the image.

                  Can you see what I did wrong?

                  Thanks,

                  Bob


                  Comment

                  • Neal

                    #24
                    Re: Simple CSS question?

                    On Wed, 22 Sep 2004 23:25:41 GMT, wrote:
                    [color=blue]
                    > .single li{
                    > text-align: left;
                    > margin: 0; padding: 0;
                    > }
                    >
                    > .single{
                    > list-style: none;
                    > }[/color]

                    You're so damn close! BTW, text-align: left is almost always the default
                    rendering for anything, no need to use that.
                    [color=blue]
                    > As you can see, I am not CSS proficient and am not sure how to create
                    > single
                    > lines of <li>'s without the bullet and indent.[/color]

                    The padding is also on the ul. Set that to margin: 0 and padding: 0 as
                    well, then change as you see fit.
                    [color=blue]
                    > Also, the Book information
                    > did not wrap around the image.[/color]

                    Put the image before the heading, and float the image left.

                    Try all that, lemme know.

                    Comment

                    • Lauri Raittila

                      #25
                      Re: Simple CSS question?

                      In article <opseqe54xjicz8 n2@news.individ ual.net>, rijk@opera.com says...[color=blue]
                      > On Wed, 22 Sep 2004 13:52:24 GMT, wrote:
                      >[color=green]
                      > > Hi Folks,
                      > >
                      > > I am new to CSS and have a very basic question.[/color]
                      >
                      > In which case, you might find it an interesting challenge to first try
                      > some things yourself... That way, you learn the most.[/color]

                      And, 50% advice is most likely to be bullshit...
                      [color=blue]
                      > Any specific reason to avoid <br>?[/color]

                      If you someday decide to style your things again, you may be sorry you
                      used <br> instead of <div>. You need to edit HTML again.

                      <br> is good in cases where there is line break, and nothing else.
                      [color=blue]
                      > This is OKish even for semantic purists, and doesn't even require style
                      > sheets:[/color]

                      Surely it is not. That surely is not what most people understand what
                      paragraphs are. Tell me, in which language this would be a paragraph?
                      Correct markup would be table, or perhaps list. And I would say div would
                      be bad choise either, but certainly it is not paragraph.
                      [color=blue]
                      > <p><strong>Name :______________ __.</strong><br>
                      > Phone:_________ ____________.<b r>[/color]
                      CSS:
                      table, tr, td, th {display:block; font-weight:normal;}
                      h2 {font-weight:bold;fon t-size:inherit;}
                      HTML:
                      <table><tr><th> Name:<td><h2>__ ______</h2>
                      <tr><th>Phone:< td>______
                      ....
                      </table>
                      ....

                      2 in h2 guessed, use appropiate heading level.

                      --
                      Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>

                      Comment

                      • Lauri Raittila

                        #26
                        Re: Simple CSS question?

                        In article <200409221640.i 8MGe7X14892@mic key.empros.com> ,
                        mstemper@siemen s-emis.com says...[color=blue]
                        > My question's really more towards the other respondents. Why wouldn't the
                        > correct markup be a definition list per company?[/color]

                        Because it isn't. Address of a company is hardly a term, nor definition
                        of one.

                        DL is a table that is good for certain type of data, terms and
                        definitions.

                        OL is a table that is good if there is only one type of data, in certain
                        order

                        UL is atable with one kind of data in random order

                        TABLE is data in some other order




                        --
                        Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>

                        Comment

                        Working...