-1

I'm working on a small personal project, and for the main page, it's going to be several images, one after another, each the size of the page.

I'm try to get rid of this type of spacing:

enter image description here

Any help is appreciated, thank you!

Kuba Wernerowski
  • 337
  • 1
  • 6
  • 17
  • Can you cut and paste your HTML (and CSS)? That will show how you laid it out, what the problem is and allow another dev to post a fix. – Andrew Koper Sep 26 '16 at 19:34

3 Answers3

2

You must set in style as:

img {
    display: block;
}

Cheers

Roberto Lonardi
  • 569
  • 2
  • 10
2

Set display: block for each img. Example in the snippet below. height is set just so the image isn't too big.

img {
  display: block;
  height: 150px;  
}
<img src="http://i.imgur.com/B5vX1kN.jpg"/>
<img src="http://i.imgur.com/KYXOUfE.png"/>
Yangshun Tay
  • 49,270
  • 33
  • 114
  • 141
1

You should post your CSS and HTML code otherwise it is quite hard fix that problem.

A possible solution is

img{border:0;}

or

img {display: block;}
Mirko Conti
  • 588
  • 4
  • 17