Problem in Media Quarry
I have this img in my html and I want to shrink the image down when it hits 600px but its not working. Can someone help or explain to me how images scale down in Media Quarry
19 Replies
You're kinda missing a closing } here.. check if you're not missing one in your code
closing is here I don't really know why its not scaling down
Can you make a codepen please?
Okay sure
I just ffigured something. I just used max-width on my .left img and it works. Whats the diffference from using the normal width?
In your HTML the img has no class .left you sure it has a class name? When i removed the class it's working well now.
oh yes another one. Im targeting the outside class with my img thats why its not working on my media quarry
Thanks alot!!!!
Width
will set the img, or whatever element it is, width to the value you set and it will stay like that no matter what screen size it is. max-width
you use it to control the width of your element.
For example:
Say you have an element with a width of 90% of the screen, now it may look good on small and medium size screens but once you are on a big screens it may look.. not desirable. So you set the allowed max-width of this element to let's say 700px or any other unit, and once it reaches this number it will stop expanding and stay at that value.
Hope it make sense 😅
Ok great! Always make sure to check your class names and see if there's any typos if you're facing any problems like this or in general.one more how do I fix this? its underline means its not working
@therealmarsman
I'm gonna need a codepen again 😬
im its actually on my project web XD can I sent it via dm?
dont roast me XD
Send it here don't worry 😅
Okay wait
So basically on line 66 where my bc color is active. and when it hits the 820px I want to change it to other color which is line 27 on css
also the buttons I want to change the color of them when it hits the 820px
Media queries should be written at the bottom of your CSS file, cut all the media query styles and paste it at the bottom of the file
https://codepen.io/ThatMartianDev/pen/MWGxRwa
Is that so? I am not aware of it XD some of videos I've watched they put the mquaries affter a one section
Im going to try it
It work! Thanks a lot @therealmarsman
Im a bit tired XD
No problem! Lol