Question
Text on image - how to make it responsive
Hi. I figured out how to put text on an image. It is not a background image. Here is the code:
<body>
<div class="imagebanner">
<img src="images/happyfamily.jpg">
<div class="bannerdescription">
<p class="typicaltext">Treating Children with Trauma Attachment Issues </p>
</div>
</div>
</body>
</html>
Css-------------------
.typicaltext {
color: #000000;
font-family:Cambria, Cochin, Georgia, Times, 'Times New Roman', serif;
font-weight: bold;
font-style: italic;
text-align: left;
font-size: 22px;
}
.bannerdescription {
position: absolute;
top: 50px;
left: 50px;
}
.imagebanner{
position: relative;
}
img {
max-width: 100%;
max-height: auto;
}
---------------------------------------------------------------------------------------------------
Any ideas of how to make the text responsive? Does it have to be a background image?
Thanks
