Click here to Skip to main content
15,883,821 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
Hello, I have been doing this course for a while now and there has been some CSS code that I have seen and coded that does not work, here is the code:
.portfolio-content {
 display: grid;
 grid-template-columns: repeat(auto-fill, minmax(450px, 
 2fr)); 
 align-items: center;
 justify-content: space-evenly;
}
/* <!-- ---------------------------------- -->
<!-- About --> */
.grid-2 {
 grid-template-columns: repeat(2, 1fr);
 gap: 20px;
 text-align: left;
 margin: auto;
}



PS: Only a 10yr doing the coding

What I have tried:

I have tried asking the person on Udemy doing the course but he did not respond
Posted
Updated 28-Oct-20 23:29pm
v2
Comments
CHill60 28-Oct-20 8:35am    
Explain what you mean by "does not work" - be detailed
jraccah70 28-Oct-20 9:23am    
i have explained
Richard MacCutchan 28-Oct-20 10:36am    
No, you have not. All you have told us is, " itdoes not work", which we have repeatedly told you means nothing. If you cannot explain exactly what is wrong, what is happening when you run the code etc., then it is impossible for us to help.
[no name] 28-Oct-20 9:02am    
I think you should stick with HTML for the time being.
jraccah70 28-Oct-20 9:23am    
thank you

1 solution

Since you haven't described the problem at all, all we can do is point you to the documentation.
CSS Grid Layout - CSS: Cascading Style Sheets | MDN[^]
A Complete Guide to Grid | CSS-Tricks[^]

You also need to pay attention to browser compatibility - if you're using any version of Internet Explorer, or an old version of most other browsers, grid layout won't work.
Can I use... CSS Grid Layout (level 1)[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900