0

How can i Input a background-Image or a image in a div

Here my code

div 
{
  height: 350px;
  width: 250px;
  border: 3px solid black;  
  background: orange;
  font-family: Arial;
  Font-Size: 24pt;
  text-align: center;
  vertical-align: center;
  display: flex;
  align-items: center;
  img-src = "https://openexpoeurope.com/wp-content/uploads/2013/06/logo-moodle-1.jpg";
}

  

</style>
</head>
<body>

<a title ="My Hover Text" target = "_blank" href = "https://www.google.de"><div>My Text in the DIV-Container</div></a>

The img-src dosn't work

Thx for help

Please look @ input textfield before.

1 Answers1

0

Did you check this : https://developer.mozilla.org/fr/docs/Web/CSS/background-image ?

img-src = "https://openexpoeurope.com/wp-content/uploads/2013/06/logo-moodle-1.jpg";

would do nothing, it doesn't exist in css

OneQ
  • 1,149
  • 1
  • 8
  • 15