Kevin Miller
Posts: 0
Joined: Tue Sep 24, 2013 11:16 pm

Why won't my CSS background display in a cell?

I can't seem to add a background to a grid cell. Is it possible? If I use the following javascript on page load:

Appery('mobilecontainer').addClass('college');
Appery('buttoncell1').addClass('college');
Appery('buttoncell2').addClass('collegeselect');
Appery('buttoncell3').addClass('college');

And CSS:
.college {
background: no-repeat url("../image/collegepage1.png") 0 0;
background-size:150px 150px;
background-position:center top;
}
.collegeselect {
background: no-repeat url("../image/collegepage2.png") 0 0;
background-size:300px 300px;
background-position:center top;
}

The background applies to the mobile container but does not affect the grid cells.
What am I doing wrong that the background will not display in the cells?
i also added a button that onClick will addClass like on the pageload. But the background still won't show even if I click that.

Thank you.

Igor
Posts: 0
Joined: Tue Apr 02, 2013 12:05 pm

Why won't my CSS background display in a cell?

Hello,

Please try to debug App and check if your components use correct CSS class names. "Debugging" doc: http://docs.appery.io/documentation/d...

Return to “Issues”