afrila gunadi
afrila gunadi

Reputation: 124

Background image isn’t showing at div class in ionic

I am working on android project with ionic framework. I have www\templates\home.html in which I am using images for item icon.

my view code home.html

<ion-content>
<div class="row gray">
 <div class="col"><div class="abc"></div>
 Opening Balance</div>
</div>
</ion-content>

my css in style.css:

.abc{
 background: url('../img/icon.png');
}

Anyone have any suggestions? Thanks in advance

Upvotes: 0

Views: 2085

Answers (1)

ambe5960
ambe5960

Reputation: 2000

  1. make sure the file path is correct

  2. make sure the permissions on the file are allowed. If you copied the image from somewhere, the permissions may not allow you to use it on your project.

Upvotes: 1

Related Questions