Maarten de Wolf
Maarten de Wolf

Reputation: 182

Position a image responsive

the palm tree need to be width responsive

Hey, guys, I have a question. On the website, I'm creating the designer asked me if I could make the palm tree responsive

position: absolute;
top: -100px;

doing it like this now... every px need a media query but that's impossible. Could someone help me out with this? Is there a better solution?

Thanks for helping me out folks

Upvotes: 0

Views: 68

Answers (3)

Maarten de Wolf
Maarten de Wolf

Reputation: 182

i fixed the problem i did it with some media querys and position relative. I did forgot that relative would not disable the height of the element. So its responsive now :)

Upvotes: 0

shikai ng
shikai ng

Reputation: 135

Normally you would make an image responsive by putting it within a parent with width set to be a % value, then set the max-width of the image to be 100%.

Upvotes: 1

Tomal
Tomal

Reputation: 127

You can use % values or view port

Upvotes: 0

Related Questions