Home > Mobile >  text wont show using <h> and <p>
text wont show using <h> and <p>

Time:01-08

I am creating a simple art profile for fun, I have a banner and a navbar. I tried to put in text:

Welcome to my art profile. This profile contains all my artworks from the previous years.

But this wont show on my page.

I checked the padding of my instructio nand navbar, bot of them should not be in the way. These are the only 2 things added to the code. I simply want the text to appear on the page.

CodePudding user response:

Alright, first off, add your code between 3 backticks (`). I looked at what I saw when you can edit an answer, and this is the code I saw:

<div id="main-content">
  <div>
    <h>Welcome to my art profile. This profile contains all my artworks from the previous years.</h>
  </div>
</div>

Second, <h> is not a tag. You are probably looking for <h1>, <h2>..., <h6>.

This is your improved code:

<div id="main-content">
  <div>
    <h1>Welcome to my art profile. This profile contains all my artworks from the previous years.</h1>
  </div>
</div>

Next, since you said there isn’t a lot that’s affecting your HTML, just post all the code. There is an “id” called “main-content”, which leads to believe some part of your code is causing the text not to show.

This website also isn’t for editing simple code mistakes, which, I will admit, is subjective.

You need to read this: https://stackoverflow.com/help/how-to-ask

EDIT: Format your CSS you added in your comment. It’s difficult to make it out. I don’t have enough reputation to edit, or make comments.

  • Related