I am trying to create a top-level menu that you would see in most applications using HTML, CSS and Javascript. I know that there are a ton of pre-built ones, but I want to create my own.
| File | Edit | Help |
| New |
| Save |
| Save As |
I'm trying to use different CSS styles to get the following list in the layout right. Is this a suitable HTML structure, or would you recommend another? What CSS is necessary for the correct layout of the menu? At the moment, I'm not interested in functionality.
I am open to any HTML 5 methods, as this is just a personal project.
<ul>
<li>File</li>
<ul>
<li>New</li>
<li>Save</li>
<li>Save As</li>
</ul>
<li>Edit</li>
<ul>
<li>Cut</li>
<li>Copy</li>
<li>Paste</li>
</ul>
<li>Help</li>
<ul>
<li>About</li>
</ul>
</ul>
Steve source
share