Hello StackOverflow,
I'm currently developing a simple page.
Does anyone know of any way to overlay a texture image over text? It seems like it's not possible with the current spec, but please let me know if this is possible.
Thanks and take care!
Hello StackOverflow,
I'm currently developing a simple page.
Does anyone know of any way to overlay a texture image over text? It seems like it's not possible with the current spec, but please let me know if this is possible.
Thanks and take care!
Not with pure CSS alone, and certainly not in a cross browser compatible way. Best to just make it a transparent .png image.
You can't overlay an image over text with native CSS 2.1, That will not be implemented into CSS 3.0 either. The best practice is to use a background image and still use your text in the <h1> tag and hide it with CSS.
<style>
h1 { background:url(images/imagepath.png) no-repeat; height:50px; width:300px; text-indent:-10000px; }
</style>
<body>
<h1>Insert Text Here</h1>
</body>