Learn the necessary steps to ensure that your content, including videos and images, is displayed correctly using HTML and CSS

I recently put together a simple webpage using a tutorial I found online. The layout includes two videos and two images arranged in a horizontal column, with the potential for more images to be added later on. Everything was looking good until I inserted the images below the videos and title. Unfortunately, this caused the video and title to get cut off and prevented me from scrolling up properly. I suspect the issue lies within the wrapper id in my CSS code. I would greatly appreciate any guidance on how to rectify this problem and ensure that my content displays correctly.

Below is the code snippet:

@charset "utf-8";
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}

body {
  height: auto;
}

.wrapper {
  position: fixed;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: linear-gradient(-200deg, #FEDD00, #FF6C2F);
  ...
<body>
  <div class="container">
    <input type="checkbox" id="active">
    <label for="active" class="menu-btn"></label>
    <div class="wrapper">
      <ul class="menu">
        <li><a href="index.html">Home</a></li>
        <li><a href="3d.html">3D</a></li>
        ...
    </div>
  ...
</body>

This is how the page should look:

https://i.sstatic.net/xfOo0.jpg

Here's a preview of the menu appearance:

https://i.sstatic.net/kdkjf.jpg

However, once I add the extra images as highlighted in the code, the title and top video end up being cutoff and I lose the ability to scroll upwards:

https://i.sstatic.net/uoaN1.jpg

Answer №1

Update your CSS .content styling with the following code snippet.

.content {
    position: fixed;
    z-index: 0;
    text-align: center;
    width: 100%;
    color: #202020;
    height: auto;
}

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Restrict Text Input Field to Accept Only Specific Domain

Hey there! I've set up a text input box for users to link their Tripadvisor page to their profile. I want to make sure that when they paste the URL in, it is checked for the correct format. For example, if someone pastes: or , then allow the link. Ho ...

Bootstrap: Arrange multiple images horizontally within a row

I am trying to design a list item for a game that includes a background, an iconholder with an icon, a title, description, and up to three resources. I have been experimenting with Bootstrap and attempted using a container-fluid with an inner row but the i ...

Having dual fixed navigation bars on a single webpage

I am looking to create two fixed navigation bars, one at the top and another in the center of the page. The idea is that when scrolling reaches the second nav bar, the first one should hide (or become relative) and the second one should become fixed. Then, ...

Increase the vertical distance between rows in a table

Having some issues with customizing a data grid that I developed. Is there a way to eliminate the header bottom border and insert spacing between each row in the table? View Demo Example Code: <dx-data-grid style="margin-top:50px" class="table" [dat ...

The ng-controller directive is not functioning accurately

I attempted to execute the following basic HTML: <!DOCTYPE html> <html ng-app="tempApp"> <head> <script src="js_libs/angular/angular.min.js"></script> <script src="js_libs/angular/bootstrap.js"></script&g ...

Submit form data to MongoDB upon submission

In my node express setup, I have integrated functionality to store values entered in checkboxes and text areas into a MongoDB database. Initially, users could calculate a score by clicking a button associated with checkboxes, and then post the information ...

Enhancing webpage design by dynamically changing borders and headers using JavaScript

I have implemented a fixed positioning for the table headers using the following code: onScroll={() => { document.querySelector('thead').style.transform = `translate(0,${this.scrollRef.scrollTop}px)`; }} However, when I scroll the ta ...

CSS 4.0 Validation Error: The property name "-webkit-text-decoration" is unrecognized in this context

After completing the Udemy course The Complete ASP.NET MVC 5 Course, I encountered an issue with Bootstrap. Despite having the latest versions of Bootstrap, jQuery, and popper.js installed, the functionality simply did not work as expected on my project. I ...

How can one use Selenium's XPath or CSS selectors to retrieve an element based on the text of its inner element or the text of the current element?

Exploring the code below: <section id="section2" class="MightChange1 MightChange2"> <div id="dynamicIdxxx" class="dynamic1 dynamic2 dynamic3"> <div id="againDynamic" ..> <div id="someDynamicCanBeRelayed" class="xyz"&g ...

CSS fixed positioning involves positioning an element relative to the

My website includes a div positioned below the header that contains quick links. I have implemented the solution from http://davidwalsh.name/persistent-header-opacity to ensure this div remains on-screen at all times. However, I would like it to appear a ...

Getting the selected value from a dropdown button that utilizes the @Html.DropDownListFor tag helper in ASP.NET Core MVC

I am currently working on a dropdown button that is populated using the HTML tag helper @Html.DropDownListFor. The code snippet for this button looks like: <div class="col-sm-3" id="valueSetParent"> @Html.DropDownListFor(model ...

Leveraging Firebase for data storage in creating XML files

According to my understanding of the firebase documentation, data that is inputted is converted into JSON format. The easiest way to connect to firebase is through the use of javascript. However, is it feasible to utilize the JSON data in firebase to gen ...

Experiencing Challenges with JavaScript Implementation Within an HTML Document

Code: <!DOCTYPE html> <head> <script type="text/javascript" src="jquery-3.3.1.js"> </script> <script type="text/javascript"> $(function() { alert("Hello World"); }); </script> <meta charset ...

Describe the CSS that targets pseudo-elements on an individual element

Perhaps a Repetition: CSS Pseudo-classes with inline styles Could an example like this work... <span style="this:hover{color:blue}">Changes color to blue when hovered</span> ...be doable? ...

Is there a way to make a picture fill the entire background?

Is there a way to make pictures expand across an entire page with different resolutions? I'm trying to achieve this effect but unsure how. Take a look at my current example: . ...

Assigning the XSL value as an identifier for the element

I'm attempting to generate an HTML file from XML by using XSLT. One of the challenges I'm facing is utilizing a value extracted from the XML as an ID for a specific element on the page. Unfortunately, the XSL fails to compile when I attempt this. ...

Ways to split images and text in list items using CSS

Can the text be formatted in a specific location on the page, separate from the image and heading? This is the HTML code I am currently using: <div class="tab-pane container fade" id="environmental"> <div class="row"> <div class="c ...

Adjust the point color of landmarks in Face-api.js

I need to customize the pointColor and lineColor in my code, but I'm not sure how to do it. I am using the fast-api.js library and haven't come across any examples of customized Landmarks Styles. export const drawResults = async (image, canvas, r ...

Django is indicating that the path is not reachable

I've been struggling with a seemingly silly issue in my code. I can't figure out why it's not working properly. Here is the directory structure of my Django Project: https://i.sstatic.net/0tVo4.png The HTML file I'm targeting (index.h ...

Tips for verifying the contents of a textbox with the help of a Bootstrap

I am still learning javascript and I want to make a banner appear if the textbox is empty, but it's not working. How can I use bootstrap banners to create an alert? <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8&g ...