[Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Mobile Website Pixel density problem !

Posted on 2013-05-13
3
Medium Priority
?
387 Views
Last Modified: 2013-05-14
Hi Experts,

In my mobile website layout looking good only the below 150 pixel density mobile devices., otherwise  layout distributed like have zooming problem above 150, 200to300 pixel density mobile devices.. How control pixel density in css?

i want to looking in my mobile website support to all pixel density mobile devices need a same resolutions of layout..

Plz guide me..
0
Comment
Question by:codeoxygen
  • 2
3 Comments
 
LVL 53

Accepted Solution

by:
COBOLdinosaur earned 2000 total points
ID: 39162169
AFAIK you cannot control the pixel density.  That is a property of the hardware of the device. The device manufacturers optimize the pixel density of the device to the characteristics of the overall hardware package.  

Normally developers are only going to be concerned with resolution to fit and position content correctly.  If your images do not show well for some devices, then you need multiple images optimized for each device.  There is no circumstances where any presentation is going to lok the same in all devices, because they do not all use the same software, firmware or hardware to geneate presentation.

Cd&
0
 

Author Comment

by:codeoxygen
ID: 39164189
Thanks for your response.

@media screen and (max-device-width: 380px){
  /* some CSS here */
}
@media screen and (max-device-width: 420px){
  /* some CSS here */
}
...
...
@media screen and (max-device-width: 1200px){
  /* some CSS here */
}
....
..
above type of  css i'm using in my mobile layout. it's the right way? or any useful links plz send me.,
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 39165555
It depends on what you are trying to do.  max-device-width ignores orientation and re-sizing because it refers to the rendering area available for display.  While max-width is responsive because it refers to the current viewport and so the value being tested changes if the orientation changes or the window is re-sized.

Without an actual page this is just academic.  The correct coding in any specific situation is 100% related to the content and how you want it rendered.  With no content to consider, then all solutions are both correct and incorrect.

Cd&
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction If you're like most people, you have occasionally made a typographical error when you're entering information into an online form.  And to your consternation, the browser remembers the error, and offers to autocomplete your future entr…
This article discusses four methods for overlaying images in a container on a web page
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
In this tutorial viewers will learn how to style different bullet points for unordered lists in CSS. Begin with a normal unordered list; the default bullet point is a solid circle: In the CSS, create a defined class of unordered list by typing "ul.S…
Suggested Courses
Course of the Month20 days, 13 hours left to enroll

865 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