Why is my code not working?

Hello this is my code in css and then at the end i will post HTML code…PLEASE HELP ME WHY TEXT IS NOT SHOWING ON MY WEBISTE FOOTER …i am trying to fix this for 2 days and i cant …PLEASE HELP …it showing background but not text ,please help me

.footer1{
background-size: cover;
background-color:rgb(88, 90, 83);
height: 450px;
clip-path: polygon(0 15%,100% 40%,100% 100%,0 100%);
color: aliceblue;
text-align: center;
z-index: 100;
}
.footer-primary{
color: aliceblue;
position: relative;
z-index: 100;
text-align: center;
}
HTML

    <h2 class="footer-primary">
    <span class="text-of-footer-main">Engman Online Photorgraphy Institute </span>
<span class="text-of-footer-sub">is where learning happens </span>
<p class="copyright">Copyright &copy;2023 Engman Online Photography Institute
 All Rights Reserved </p>
**Yust select a tag to post in this category. Please find the tag relating to the section of the course you are on E.g. Forms, Structure**

When you ask a question, don’t forget to include a link to the exercise or project you’re dealing with!

If you want to have the best chances of getting a useful answer quickly, make sure you follow our guidelines about how to ask a good question. That way you’ll be helping everyone – helping people to answer your question and helping others who are stuck to find the question and answer! :slight_smile:

Hi There,

I am just starting my coding journey, but looking at the CSS and the fact you mentioned you can see the background and not the text, makes me think you have a text colour match against your background? I might be completely wrong, but have you tried changing it to see if the text becomes visible?

.footer-primary{
color: aliceblue;

.footer1{
background-size: cover;
background-color:rgb(88, 90, 83);
height: 450px;
clip-path: polygon(0 15%,100% 40%,100% 100%,0 100%);
color: aliceblue;

thank you but not …
I change the color to black, red,I play with this .,I even did opacity low on the background to show true but is not showing …
when I hide the background then is shows text , but when I put the background back text is hidden behind …
I am just starting too and don’t know what to do …
thanks any way

Please if someone have more ideas …please help …

Hi, I’m going through your code and I don’t see the html element with the footer1 class but I’m assuming it’s a div containing the h2 and p tag, if this is the case try to make this modification in your css code and let me know if it’s what you needed :slightly_smiling_face:

footer1{
    background-size: cover;
    background-color: rgb(88, 90, 83);
    height: 450px;
    clip-path: polygon(0 15%,100% 40%,100% 100%,0 100%);
    color: aliceblue;
    text-align: center;
    display: flex;
    justify-content: end;
    flex-direction: column;
}

First of all, I would suggest using the tag if you want to create one.

Second, You are adding a background-cover without an image at all.

Third, why do you have a z-index? What is the purpose of that?

Fourth, you do not show us where you use the footer1 class.

hey guys, this should look like this …someone -developer from Hungary on stuck overflow fix it for me footer{

  background-size: cover;
  background-color:rgb(88, 90, 83);
  height: 450px;
  clip-path: polygon(0 15%,100% 40%,100% 100%,0 100%);
  color: aliceblue;
  z-index: 1;
  position: relative;
  bottom: 0;
}

footer h4,
footer p{
  width: 100%;
  text-align: center;
  position: absolute;
  bottom: 20px;
  padding: 0 1rem;
  z-index: 100;
}

footer h4{
  padding-bottom: 1rem;
}
<footer>
<h4>Engman Online Photorgraphy Institure is where learning happens</h4>

<p>Copyright &copy;2023 Engman Online Photography Institute All Rights Reserved </p>
</footer>

Expand snippet

Share

answered yesterday

adampweb's user avatar

adampweb
1,08411 gold badge99 silver badges1818 bronze badges

Hello. I would like to know why my image isn’t working. Click here

The src attribute url does not seem to work.

Why is it not working?