Image not displayed online?

HTML:

<img src="file:///C:/Users/magnu/Downloads/IMG_0342.JPG" alt="logo">

When I run the code in a browser locally on my PC, the image displays. But not when I view the site online. What am I doing wrong?

CSS:

img{
    width:210px;
    length:210px;
    -webkit-transform:rotate(270deg);
    -moz-transform: rotate(270deg);
    -ms-transform: rotate(270deg);
    -o-transform: rotate(270deg);
    transform: rotate(270deg);
    position:absolute;
    left:600px;
    top:300px;
  }


you have to set its location comppared with the location the html file for example if html file is located in c:/html/ and img is located in c:/ you should to set img src as follow src=”../img.jpg” “../” to retun back by one folder

Put your image on server. There are many options using which you can put your image online like imgur, imgbb

instead of giving length give height to your image.

Hope this helps.

IN the src you have to write the path without “file///”:

<img src="C:/Users/magnu/Downloads/IMG_0342.JPG" alt="logo">