htmlcssdreamweaver

How can I integrate in html pages 2 different CSS styles for 2 diferent images?


Can anyone help me?

How can I integrate in html pages 2 different CSS styles for 2 diferent images, both being separated vertically by a space?

See the paintings below. They have different sizes, different styles.

enter image description here


Solution

  • Something like this. You may change the dimensions anytime

    .img, .firstImage, .secondImage {
        border: 1px dotted blue;
        width: 200px;
    }
    
    .firstImage {
        float:left;
        border: 1px solid #ddd;
        border-radius: 4px;
        padding: 5px;
        width: 150px;
    }
    
    .secondImage {
        float:right;
        border: 2px solid #fff;
        border-radius: 2px;
        padding: 3px;
        width: 120px;
    }