SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Wizard jag5311's Avatar
    Join Date
    Jan 2003
    Location
    Somewhere in Indiana
    Posts
    3,082
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Don't know which selectors to use

    Well, Lets see if I can describe this good enough. I have the section where my main body text will go. Since I am using tables and cells, I want to have the body section surrounded within a bordered section, but not surrounding the h2 i have. I currently have <p></p> surrounding the body section, but if I add another set of <p></p> within that same body, I don't want that new paragraph having the same attributes as the paragraph above. I am basically looking for a solution without using another table.

    Is there something like

    p+p or p>p or something where this code

    Code:
    <td id="bodytext"><h2>Information</h2>
    <p>Body Text Body content goes her
    ethrough a top-down, proactiveapproach we can 
    remain customer focused and goal-directed,innovate
    and be an inside-out organization 
    which facilitates sticky web-readine
    ss transforming
    action-items with revolutionary relat
    ionships that deliver viral markets
    and grow e-business supply-ch
    ains that expedite seamless relationships andtransform 
    back-end relationships withthrough a top-down, proact
    ive approachwe
    can remain customer 
    focused and goal-directed, 
    innovat																																																																																																																																																																																																																																																							 </p>
    </td>


    Now, that is only 1 set of p tags. Imagine a black border around only the p tags,
    but the very final closing p tag would be the absolute last tag in the box.
    So any other p tags could fall within the first set of p tags and appear within the 1 bordered box

    Make sense?

    Kinda like this

    Code:
    <p>
    Hi ya, this is some text, this is a paragraph
    <p>This is some more text, how you doing. YEA!!!!</p>
    </p>
    That probably isn't even legal. I might be looking at a div solution here for that one table cell.

    Your thoughts.
    PS - I can't figure out why this window decided to expand across the screen, it looks fine in this window I am typing

  2. #2
    SitePoint Enthusiast
    Join Date
    Sep 2003
    Location
    Germany
    Posts
    36
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If all you want is a border around all the content of your table cell, then yea, enclosing the text with a div and adding a border to that is the way to go. Not sure if nesting paragraphs is allowed, but in your case thats nothing you need or want.
    Hope i understood your question and this makes sense

  3. #3
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,514
    Mentioned
    182 Post(s)
    Tagged
    6 Thread(s)
    Not sure if nesting paragraphs is allowed
    No its not allowed! Either its a paragraph or it isn't .

    Use a div to enclose your paragraphs as martin3 suggested above.

    Paul

  4. #4
    SitePoint Wizard jag5311's Avatar
    Join Date
    Jan 2003
    Location
    Somewhere in Indiana
    Posts
    3,082
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Perfectly answered my question.

    Thanks to both of you.


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
  •