Solved

background image won't fill screen on my android phone

Posted on 2016-08-04
6
59 Views
Last Modified: 2016-08-31
The background image of this page fills the screen on my computer but not on my LG Stylo. Please take a look at the css and html and let me know how to remedy that. www.dijitalrealm.com/JCMusic/Jukebox2.html.

Thanks,
John
0
Comment
Question by:gabrielPennyback
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 22

Accepted Solution

by:
Kim Walker earned 168 total points
ID: 41743685
I don't see anything in your code that would change the size of the background image based on screen size. So it should extend way beyond the left and right sides and bottom of your android phone screen. But it would be clipped at the edges of the body element of which it is the background image. So if it isn't filling the screen of your phone, that would suggest that the body element doesn't fill the screen. Is the color of the area that isn't filled with the image dark gray? The background color for your body is dark gray which should appear anywhere the image doesn't cover the body element. If it is not dark gray, then the body element is somehow smaller than the screen.

Since you have established the left and right margin of your body element to auto, if the body element is somehow narrower than the screen, there should be a white area on both the left and right sides. Is this the case on your phone?

By the way, the background-position property is usually expressed in two values, one for horizontal and one for vertical positions. When only one value is supplied, the other value defaults to center. So background-position: top; equates to background-position: center top; and background-position: left; equates to background-position: left center.
0
 
LVL 46

Assisted Solution

by:Jackie Man
Jackie Man earned 166 total points
ID: 41744042
Your web page appears to be pretty normal for a webpage as you have not put the following code before your content html.

<div id="wrapper">

A lot of sites don't span the full screen length (i.e. fixed width sites), so webmasters use a "wrapper" to set the appropriate width and act as a full screen would.

Source: https://www.sitepoint.com/community/t/why-do-most-developers-put-div-id-wrapper-firstly/4515
0
 
LVL 25

Assisted Solution

by:lenamtl
lenamtl earned 166 total points
ID: 41752821
Try to add the viewport Meta t your page to see if this fix the problem.

 <!-- Tell the browser to be responsive to screen width -->
 <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">

Open in new window

1
 
LVL 1

Author Comment

by:gabrielPennyback
ID: 41758526
Thank you for your help on this, guys. lenamtl, I meant to split the points evenly between the 3 of you but i hit the wrong button before finishing and you got left out. I don't know how to re-do the awarding process so please forgive me.

~ John
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
Here, we have shared an easy step by step tutorial on how to download instagram images and videos on PC, Android Mobile and iOS mobile.
In this tutorial viewers will learn how to style rounded corners for elements in CSS using the border-radius property Begin with a normal styled element such as a div: To style all four corners of the div to be the same degree of roundness, use the …
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

729 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