Background for my carousel
Solved
Debutant en webmastering
Posted messages
444
Status
Membre
-
Debutant en webmastering Posted messages 444 Status Membre -
Debutant en webmastering Posted messages 444 Status Membre -
Hello,
I’ve been trying to set a background image for the carousel on the website http://www.starplugins.com/killercarousel using background-url: (bg.jpg). The problem is that when I add this line, nothing loads and I get a completely blank page.
Before integrating the CSS line:
http://ioj.com/v/t9pjb
And after:
http://ioj.com/v/i5vx2
If you know what’s wrong, I would appreciate an answer because personally, I have no idea.
--
Best regards, Beginner in web mastering
I’ve been trying to set a background image for the carousel on the website http://www.starplugins.com/killercarousel using background-url: (bg.jpg). The problem is that when I add this line, nothing loads and I get a completely blank page.
Before integrating the CSS line:
http://ioj.com/v/t9pjb
And after:
http://ioj.com/v/i5vx2
If you know what’s wrong, I would appreciate an answer because personally, I have no idea.
--
Best regards, Beginner in web mastering
1 réponse
Hi, back already :)
To display your background image, you can add it directly by replacing the color with your image like this:
background: #000000; <--This corresponds to the black color
background: url('images/fond.jpg'); <--And this to an image
Otherwise, I recommend for a cleaner job to separate the CSS from the HTML, for example:
And then in your stylesheet:
To display your background image, you can add it directly by replacing the color with your image like this:
background: #000000; <--This corresponds to the black color
background: url('images/fond.jpg'); <--And this to an image
<div id="carousel" style="width:400px; height:180px;background: url('images/fond.jpg');overflow:scroll;"> <--HERE THE IMAGES OF THE CAROUSEL--> </div> Otherwise, I recommend for a cleaner job to separate the CSS from the HTML, for example:
<div id="carousel"> <--HERE THE IMAGES OF THE CAROUSEL--> </div>
And then in your stylesheet:
#carousel{ background: url("images/fond.jpg") no-repeat; width: 400px; height: 180px; overflow: scroll; }
Debutant en webmastering
Posted messages
444
Status
Membre
U_u a simple Ctrl + F in Notepad and I immediately understand why it wasn't working, thanks for the answer (oh yes, 2 backgrounds for the same place has never been very practical).