Why do i get the warning element is not allowed here? HTML












0














I'm trying to make my first web page from memory after completing FCC HTML basics. Why do i keep getting warnings, saying (p element is not allowed here, same for b, head, and most other tags. I'm doing it exactly as ive been shown. This still displays, but the yellow on my Pycharm has me uneasy.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>

<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>










</b>
</main>









share|improve this question


















  • 1




    The <b> element is an inline element. If you want the text on the page to be bold, use a body{font-weight:bold} declaration in CSS.
    – ncmathsadist
    Nov 22 '18 at 22:54










  • You are also missing the <meta charset="utf-8"/> tag. Also, where is your <body> tag? The <main> tag is basically a div, it is not a substitute for <body>.
    – ncmathsadist
    Nov 22 '18 at 22:56












  • First time trying to go from memory, messed up the syntax. Thought body was <b></b>
    – Adag89
    Nov 22 '18 at 23:35
















0














I'm trying to make my first web page from memory after completing FCC HTML basics. Why do i keep getting warnings, saying (p element is not allowed here, same for b, head, and most other tags. I'm doing it exactly as ive been shown. This still displays, but the yellow on my Pycharm has me uneasy.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>

<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>










</b>
</main>









share|improve this question


















  • 1




    The <b> element is an inline element. If you want the text on the page to be bold, use a body{font-weight:bold} declaration in CSS.
    – ncmathsadist
    Nov 22 '18 at 22:54










  • You are also missing the <meta charset="utf-8"/> tag. Also, where is your <body> tag? The <main> tag is basically a div, it is not a substitute for <body>.
    – ncmathsadist
    Nov 22 '18 at 22:56












  • First time trying to go from memory, messed up the syntax. Thought body was <b></b>
    – Adag89
    Nov 22 '18 at 23:35














0












0








0







I'm trying to make my first web page from memory after completing FCC HTML basics. Why do i keep getting warnings, saying (p element is not allowed here, same for b, head, and most other tags. I'm doing it exactly as ive been shown. This still displays, but the yellow on my Pycharm has me uneasy.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>

<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>










</b>
</main>









share|improve this question













I'm trying to make my first web page from memory after completing FCC HTML basics. Why do i keep getting warnings, saying (p element is not allowed here, same for b, head, and most other tags. I'm doing it exactly as ive been shown. This still displays, but the yellow on my Pycharm has me uneasy.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>

<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>










</b>
</main>






html5






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 22 '18 at 22:50









Adag89

527




527








  • 1




    The <b> element is an inline element. If you want the text on the page to be bold, use a body{font-weight:bold} declaration in CSS.
    – ncmathsadist
    Nov 22 '18 at 22:54










  • You are also missing the <meta charset="utf-8"/> tag. Also, where is your <body> tag? The <main> tag is basically a div, it is not a substitute for <body>.
    – ncmathsadist
    Nov 22 '18 at 22:56












  • First time trying to go from memory, messed up the syntax. Thought body was <b></b>
    – Adag89
    Nov 22 '18 at 23:35














  • 1




    The <b> element is an inline element. If you want the text on the page to be bold, use a body{font-weight:bold} declaration in CSS.
    – ncmathsadist
    Nov 22 '18 at 22:54










  • You are also missing the <meta charset="utf-8"/> tag. Also, where is your <body> tag? The <main> tag is basically a div, it is not a substitute for <body>.
    – ncmathsadist
    Nov 22 '18 at 22:56












  • First time trying to go from memory, messed up the syntax. Thought body was <b></b>
    – Adag89
    Nov 22 '18 at 23:35








1




1




The <b> element is an inline element. If you want the text on the page to be bold, use a body{font-weight:bold} declaration in CSS.
– ncmathsadist
Nov 22 '18 at 22:54




The <b> element is an inline element. If you want the text on the page to be bold, use a body{font-weight:bold} declaration in CSS.
– ncmathsadist
Nov 22 '18 at 22:54












You are also missing the <meta charset="utf-8"/> tag. Also, where is your <body> tag? The <main> tag is basically a div, it is not a substitute for <body>.
– ncmathsadist
Nov 22 '18 at 22:56






You are also missing the <meta charset="utf-8"/> tag. Also, where is your <body> tag? The <main> tag is basically a div, it is not a substitute for <body>.
– ncmathsadist
Nov 22 '18 at 22:56














First time trying to go from memory, messed up the syntax. Thought body was <b></b>
– Adag89
Nov 22 '18 at 23:35




First time trying to go from memory, messed up the syntax. Thought body was <b></b>
– Adag89
Nov 22 '18 at 23:35












1 Answer
1






active

oldest

votes


















0














<main></main> is not a supported HTML tag. It should be <body></body>.



update



You are about the “main” tag. However, I do see what may be your issue. It does not appear that your closes the “html” tag and you still need to add the “body” tags.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>
<body>
<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>
</b>
</main>
</body>
</html>





share|improve this answer























  • Why is this? It's been explained to me this way in every tutorial.
    – Adag89
    Nov 23 '18 at 6:31










  • <main> is, in fact a supported HTML5 tag. It behaves like a div, and it is a semantic tag similar to <aside>, <header>, and <nav>.
    – ncmathsadist
    Nov 23 '18 at 19:10










  • Yeah, I know that was my bad @ncmathsadist
    – andre mcgruder
    Nov 23 '18 at 23:38











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53438805%2fwhy-do-i-get-the-warning-element-is-not-allowed-here-html%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














<main></main> is not a supported HTML tag. It should be <body></body>.



update



You are about the “main” tag. However, I do see what may be your issue. It does not appear that your closes the “html” tag and you still need to add the “body” tags.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>
<body>
<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>
</b>
</main>
</body>
</html>





share|improve this answer























  • Why is this? It's been explained to me this way in every tutorial.
    – Adag89
    Nov 23 '18 at 6:31










  • <main> is, in fact a supported HTML5 tag. It behaves like a div, and it is a semantic tag similar to <aside>, <header>, and <nav>.
    – ncmathsadist
    Nov 23 '18 at 19:10










  • Yeah, I know that was my bad @ncmathsadist
    – andre mcgruder
    Nov 23 '18 at 23:38
















0














<main></main> is not a supported HTML tag. It should be <body></body>.



update



You are about the “main” tag. However, I do see what may be your issue. It does not appear that your closes the “html” tag and you still need to add the “body” tags.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>
<body>
<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>
</b>
</main>
</body>
</html>





share|improve this answer























  • Why is this? It's been explained to me this way in every tutorial.
    – Adag89
    Nov 23 '18 at 6:31










  • <main> is, in fact a supported HTML5 tag. It behaves like a div, and it is a semantic tag similar to <aside>, <header>, and <nav>.
    – ncmathsadist
    Nov 23 '18 at 19:10










  • Yeah, I know that was my bad @ncmathsadist
    – andre mcgruder
    Nov 23 '18 at 23:38














0












0








0






<main></main> is not a supported HTML tag. It should be <body></body>.



update



You are about the “main” tag. However, I do see what may be your issue. It does not appear that your closes the “html” tag and you still need to add the “body” tags.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>
<body>
<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>
</b>
</main>
</body>
</html>





share|improve this answer














<main></main> is not a supported HTML tag. It should be <body></body>.



update



You are about the “main” tag. However, I do see what may be your issue. It does not appear that your closes the “html” tag and you still need to add the “body” tags.



<!DOCTYPE html>
<html>
<head>
<title>This is my website</title>
</head>
<body>
<main>
<b>

<h1>This is my Header</h1>

<h2>This is where I describe my website</h2>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut eros aliquet, convallis nulla vel, imperdiet mi. Fusce eu tellus nunc. Praesent consectetur in tortor nec eleifend. Nulla nisl neque, pretium sit amet faucibus sollicitudin, tincidunt et enim. Curabitur ipsum nisi, malesuada nec nisi eget, hendrerit ullamcorper ante. Sed pulvinar efficitur porttitor. Aliquam eleifend dapibus ipsum, dictum vestibulum lorem pellentesque eget. Aliquam efficitur nisl id sapien pulvinar interdum. Etiam molestie vulputate sapien a porttitor.

Nullam suscipit pellentesque augue. Nulla facilisi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Curabitur neque arcu, dignissim non massa in, pellentesque vehicula massa. Quisque imperdiet odio ligula, eu ornare diam blandit eu. Maecenas ac massa eu mi tempor mattis. Donec imperdiet eros justo, eu semper ex commodo sit amet. Quisque finibus velit vitae nibh consequat vulputate. Mauris venenatis egestas mauris sit amet viverra. Vestibulum venenatis iaculis lectus in placerat. Integer in ipsum nibh. Fusce vitae euismod dolor, a mollis lorem.

Maecenas feugiat accumsan ipsum, non lobortis arcu imperdiet id. Fusce pharetra dui et ultrices imperdiet. Nam sed ex ipsum. Cras at tellus lobortis, molestie leo et, pharetra neque. Nullam pharetra urna quis porta ullamcorper. Nam tempus nisl a arcu suscipit dignissim. Sed condimentum, orci ac dignissim pellentesque, nisi ante pulvinar nulla, non posuere elit ligula et erat. Maecenas eget est et arcu efficitur lacinia. Sed et nunc vel diam tincidunt laoreet. Sed ut lorem ac nulla ultrices porttitor ut vel est. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque eu enim fringilla, vestibulum lectus vel, vestibulum erat. Vestibulum quis efficitur massa. Morbi ac turpis vestibulum, consectetur quam gravida, tincidunt leo. Vivamus molestie neque nec nibh ullamcorper aliquet. Pellentesque at nunc felis.</p>
</b>
</main>
</body>
</html>






share|improve this answer














share|improve this answer



share|improve this answer








edited Nov 23 '18 at 18:19

























answered Nov 23 '18 at 6:02









andre mcgruder

1,004188




1,004188












  • Why is this? It's been explained to me this way in every tutorial.
    – Adag89
    Nov 23 '18 at 6:31










  • <main> is, in fact a supported HTML5 tag. It behaves like a div, and it is a semantic tag similar to <aside>, <header>, and <nav>.
    – ncmathsadist
    Nov 23 '18 at 19:10










  • Yeah, I know that was my bad @ncmathsadist
    – andre mcgruder
    Nov 23 '18 at 23:38


















  • Why is this? It's been explained to me this way in every tutorial.
    – Adag89
    Nov 23 '18 at 6:31










  • <main> is, in fact a supported HTML5 tag. It behaves like a div, and it is a semantic tag similar to <aside>, <header>, and <nav>.
    – ncmathsadist
    Nov 23 '18 at 19:10










  • Yeah, I know that was my bad @ncmathsadist
    – andre mcgruder
    Nov 23 '18 at 23:38
















Why is this? It's been explained to me this way in every tutorial.
– Adag89
Nov 23 '18 at 6:31




Why is this? It's been explained to me this way in every tutorial.
– Adag89
Nov 23 '18 at 6:31












<main> is, in fact a supported HTML5 tag. It behaves like a div, and it is a semantic tag similar to <aside>, <header>, and <nav>.
– ncmathsadist
Nov 23 '18 at 19:10




<main> is, in fact a supported HTML5 tag. It behaves like a div, and it is a semantic tag similar to <aside>, <header>, and <nav>.
– ncmathsadist
Nov 23 '18 at 19:10












Yeah, I know that was my bad @ncmathsadist
– andre mcgruder
Nov 23 '18 at 23:38




Yeah, I know that was my bad @ncmathsadist
– andre mcgruder
Nov 23 '18 at 23:38


















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53438805%2fwhy-do-i-get-the-warning-element-is-not-allowed-here-html%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Berounka

Sphinx de Gizeh

Different font size/position of beamer's navigation symbols template's content depending on regular/plain...