Welcome to Code Forum!

Join a community that supports you and your coding journey from day one. We strive to be a friendly, supportive community that empowers everyone to be better developers. By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!
  • Guest, before posting your code please take these rules into consideration:
    • It is required to use our BBCode feature to display your code. While within the editor click < / > or >_ and place your code within the BB Code prompt. This helps others with finding a solution by making it easier to read and easier to copy.
    • You can also use markdown to share your code. When using markdown your code will be automatically converted to BBCode. For help with markdown check out the markdown guide.
    • Don't share a wall of code. All we want is the problem area, the code related to your issue.

    GIF shows where to locate </> in the thread and or post editor toolbar.
    To learn more about how to use our BBCode feature, review our "How to post your code into threads" here.

    Thank you, Code Forum.

My image dont show

ozzymagnum

New Coder
I am trying to add a second image to HTML but it doesnt show on the website. I am talking about ''Bild2'' that is in HTML.

CSS:
.flex-container{
    display: flex;
}

  .container {
    position: relative; /* Make the container a positioning context */
    width: 1178px; /* Set the width of the container */
    height: 1000px; /* Set the height of the container */
    background: url('Bild1.jpg') no-repeat center center;
    background-size: cover; /* Make the image cover the container */
    margin-top: -35px
}


nav {
    position: absolute; /* Position the navigation menu absolutely */
    top: 20px; /* Adjust the top value to move the menu down as needed */
    left: 0;
    right: 0; /* Right should be 0 to stretch the menu across the container */
}

ul {
    list-style-type: none;
    padding: 20;
    margin: 30px;
    position: absolute; /* Position the <ul> absolutely */
    top: 10px; /* Adjust the top value to change the vertical position */
    left: -27px;
    
}

li {
    display: inline;
    margin-right: 20px;
    margin-top: 20px;
}

a {
    text-decoration: none;
    color: #ffffff;
    font-family: 'Poppins', sans-serif;
}

.flex-container.right img {
    margin-right: 300px; /* Move the image 20 pixels to the right */
    margin-top: 70px;  /* Move the image 10 pixels down */
}

HTML:
<!DOCTYPE html>
<html lang="en">
<head>
    <link href="https://fonts.googleapis.com/css2?family=Poppins&display=swap" rel="stylesheet">
    <link rel="stylesheet" href="munamii.css">
    <title>Munamii Cakery</title>

</head>
<body>
  
    
     <header>
        <nav>
            <div class="container">
                <div class="flex-container left">
                    <ul>
                        <li><a href="#">Butik</a></li>
                        <li><a href="#">Om Oss</a></li>
                        <li><a href="#">Adress</a></li>
                        <li><a href="#">Kontakta Oss</a></li>
                    </ul>
                </div>
            </div>
        </nav>
    </header>
        
        <div class="flex-container right">
            <img src="Bild2.jpg" alt="">
        </div>
        
          
     <main>
     </main>
        
        <footer>
        
    </footer>

</body>
</html>
 

Latest posts

Buy us a coffee!

Buy me a coffee.
Back
Top Bottom