I am working on developing a website using Python's Django framework. At the frontend part, I am trying to make a division block to appear 3 seconds after you have accessed the page.
I'll share with you my code:
.computerScienceContent{
text-align: center;
display: block;
position: relative;
margin-top: 10px;
margin-bottom: 50px;
width: 700px;
margin-left: auto;
margin-right: auto;
padding: 30px;
padding-left: 20px;
animation-delay: 2s;
animation: 1s linear 1s slideInLeft;
}
The above cod is used for displaying the block.
This code is used to display it from left to right.
@keyframes slideInLeft {
0% {
transform: translateX(-100%);
}
100% {
transform: translateX(0);
}
}
This is the django code from the html that I am trying to displaying with delay.
<div class="computerScienceContent">
{% for cat in category %}
<div class="csDivContent" id="slide">
<div id="slide">
<h4>{{ cat.name }}</h4>
<img src="{{ cat.img.url }}" alt="image" class="img">
</div>
</div>
{% endfor %}
</div>
Basically, I want the block to be displayed 3 seconds after I access the website, one entry at a time, from left to right (there are only 4 entries). If anybody can help, I will be very happy! Thank you so much for your time !
Later edit: I provided a code sample: https://www.w3schools.com/code/tryit.asp?filename=GND7OAP8A72U