My tribute page on flavia pennetta

My tribute page on flavia pennetta
0

#1

Hi, this is my tribute page: https://codepen.io/Mister99/pen/aLgrjL
I expect some feedback,thanks


#2

Hi @gianni86p,

HTML inspector:

  • ‘weight’ is not a valid attribute of the <img> element.
<img class="float-right m-5" src="..." alt="Pennetta in 2015" weight="100"height = "100">
  • The <figcaption> element cannot be a child of the <section> element.
<section class="text-center">
 <iframe class="embed-responsive-item" width="560" height="315" src="https://www.youtube.com/embed/A4Ic9kwwLzc?rel=0&amp;showinfo=0" frameborder="0" allowfullscreen></iframe>
  <figcaption class="figure-caption text-dark">Indian Wells 2014 - Final Highlights - Pennetta <em>vs</em> Radwanska</figcaption>
</section>

MDN documentation:
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figcaption

The HTML <figcaption> element represents a caption or a legend associated with a figure or an illustration described by the rest of the data of the <figure> element which is its immediate ancestor.

Permitted parents:
A <figure> element; the <figcaption> element must be its first or last child.

Cheers and happy coding :slight_smile:


#3

Thanks for your feedback: slight_smile: :slight_smile:
I still have a lot to learn, I hope to improve, I’m happy to receive your comments and respond to them, so I also learn languages that are my weak point :
:grinning:
I have some questions:
So the tag figure should I put it out of the tag section?
Can not I use tag figcaption for video? for its description use a simple tag p?

Thanks:smiley::smiley:


#4

you are welcome ( I also use the forum to practice english :slight_smile: )

I think you can use the figure tag alone ( is more specific than section ).

The HTML <figure> element represents self-contained content, frequently with a caption (<figcaption>), and is typically referenced as a single unit.

The HTML <section> element represents a standalone section of functionality contained within an HTML document, typically with a heading, which doesn’t have a more specific semantic element to represent it.

I think that you can use figcaption tag for video, because video is flow content.

MDN figure:
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figure

Permitted content:
A element, followed by flow content; or flow content followed by a element; or flow content.

MDN flow content:
https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/Content_categories#Flow_content

<video>

Cheers and happy coding :slight_smile:


#5

thanks for your precious tips, I realize that I have a lot to learn :smiley