Text as a bg

A

Andrew Poulos

Is it possible to add a background image to, say, a DIV but that the
image is in fact some text, without first making the text itself into an
image?

The project I'm working on displays specific "kinds" of information.
When a specific type is displayed there's a corresponding heading that
goes with it. I'd like to be able to move the heading to the style sheet.

I've been looking at writing the heading using DOM methods based on the
class associated with the information but as the class is tied to the
kind of information I thought maybe I could use the class more directly.
(Rather than querying the information for its class.)

Andrew Poulos
 
E

Evertjan.

Andrew Poulos wrote on 17 apr 2005 in comp.lang.javascript:
Is it possible to add a background image to, say, a DIV but that the
image is in fact some text, without first making the text itself into an
image?

No. Your question gives the answer: an image is an image.
The project I'm working on displays specific "kinds" of information.
When a specific type is displayed there's a corresponding heading that
goes with it. I'd like to be able to move the heading to the style sheet.

Use display:none; or z-index:; absolute:; positioned <div>s

Better ask a css group,
unless you want to manipulate className or class content with Javascript

I've been looking at writing the heading using DOM methods based on the
class associated with the information but as the class is tied to the
kind of information I thought maybe I could use the class more directly.
(Rather than querying the information for its class.)

Incomprehensible ;-)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,265
Latest member
TodLarocca

Latest Threads

Top