Solved

Resize image differently for phone and computer

Posted on 2013-11-17
2
187 Views
Last Modified: 2013-11-18
How do I resize an image differently for phone and computer?
0
Comment
Question by:burnedfaceless
2 Comments
 
LVL 52

Accepted Solution

by:
Scott Fell,  EE MVE earned 500 total points
ID: 39656330
In your css, you can use media queries https://developer.mozilla.org/en-US/docs/Web/Guide/CSS/Media_queries

@media (max-width: 768px) {
  img {
    width:700px;
  }
}
@media (min-width: 768px) {
  img {
    width:900px;
  }
}

Open in new window

In the above, if the viewport is below 768 one a smaller width is used, in the larger screen a larger width is used.
0
 

Author Closing Comment

by:burnedfaceless
ID: 39657417
Thank you for the link and the example
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Recently, we decided that in order to stay competitive in today's IT world, we were going to have to develop and deploy a mobile app for our users and do it quickly. We felt that we were already behind the curve. Users of technology today are mov…
In this article we will discuss all things related to StageFright bug, the most vulnerable bug of android devices.
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now