Solved

background image won't fill screen on my android phone

Posted on 2016-08-04
6
53 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
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 43

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

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
moto 4g plus memory usage 30 32
Input box gone wrong 8 24
android secure ftp 3 38
ftp to port 21 4 43
The case of the missing phone talks about the way a small electronic gadget (the mobile phone) has penetrated into our lives and has made us addicted to it.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …
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 …

809 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