Skip to content

Baramon Lares#3

Open
Barrylares wants to merge 1 commit intoprofstein:masterfrom
Barrylares:master
Open

Baramon Lares#3
Barrylares wants to merge 1 commit intoprofstein:masterfrom
Barrylares:master

Conversation

@Barrylares
Copy link

Assignment 1

Baramon Lares

Just Look at Assignment 1. ignore other files.

Look at cloud 9 if you have questions https://github.com/profstein/inClassDelete

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting choice to put lists within lists. In this case it may be more complex than you need.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When i researched it was the only way to have an

    tag inside of an
      . The solution I found was to have them within an
    1. which was allowed. Thanks for the feedback.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't get a chance to make my comment more complete.

Yes, you are correct that to have a list within a list the inner list has to be inside of the html <li> </li> elements. And you did add them in correctly.

What I would like you to rethink is which elements you use. You really want to accomplish a few things with the markup:

  1. show that the question and answer are a pair (related elements).
  2. Have something be different between the two so that you can style the questions differently than the answers.
  3. Use semantic markup as much as possible.

I should say up front that there is no perfect answer for how to mark up this assignment — see this discussion. There is no Q&A element in HTML5. So I'm more looking that you have made an effort to do the three things above.

If you want to keep them in a list one way would be to use a definition list, sitepoint reference

<dl>
    <dt>Question here</dt>
    <dd>answer</dd>
    <dt>Question  2 here</dt>
    <dd>answer 2</dd>
</dl>

and so on. This fultills one and two pretty well (ideally you would have a class or id on the dl ), but it's a bit questionable on 3 as to whether this is the best semantically.

Another alternative is to use something like headings for questions and paragraphs for answers

<h3>question</h3>
<p>answer</p>
<h3>question 2</h3>
<p>answer 2</p>

The problem here is that you don't have any thing for 1 (show the two are a pair). You could add <div></div> tags around each pair to do that. It would create more markup though and semantics is again questionable. For that I would say it depends on how involved the questions and answers are. You can also add a class to all of the answer p's to help distinguish them from other paragraphs on the page and make styling and separation of the pairs easier.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review, and your definitely right. Mentally I didn't create it for mark-up but yes adding divs and classes will give me more control over them all.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants