Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Question on hiding text.

Status
Not open for further replies.

Guest_imported

New member
Joined
Jan 1, 1970
Messages
0
Hello all.

I'm just a kid with a idea. I'm tinkering with Dreamweaver 4, and I just got a idea. I made a table, with 2 divs. One div was going to have a picture in it, and the second was going to have text in it.

I wanted it so that the picture overlapped the text. That's part 1.

Part 2.

I then wanted it so that the text, in the second Div, was hidden, thereby giving the viewer a clear view of the picture.

Part 3.

Then--I wanted to be able to write a Javascript, or at least find one.. that let me roll my cursor over the picture, and reveal the hidden text on the other table behind it...

Does that makes sense? Or did I write that in a confusing manner?

If you are able to help, please do, and thank you for listening!
 
You don't need javascript.

Make your two layers, position them as yuou will, then have a muck about with the layers behaviour.

Mark the first layer, click on windows, behaviours then the + button. Choose show/hide layers on rollover.

Can't really give more help than that as I've jsut got home from the pub.... You will work it out.

 
1. Position your two layers directly over eachother.

2. Put in your image and your text.

3. Change your layer z-index number so your text layer is overlapping the image layer.

4. Change the status of your text layer to hidden.

5. Click on your image. Choose Behaviors and chose show/hide layer. Check to show layer (hidden layer).

6. Make sure that the behavior runs on mouseOver.

Thats it. This should create the affect you want.
 
Egad, that was highly simple.

Now, if only my dang tabls would overlap, I'm sure I could get the rest of your steps down. I just don't know what exactly is a z-index layer number, because, I don't see any number to edit.
 
Pay no mind to that last comment I said. I figured it out, and Thank you so very much. I only have the slight problem of the two divided layers not being in the dang table, but I can figure that out. Again Thanks
 
Are they both declaired within the table?

As in:

Code:
<table>
<tr><td>
<div> IMAGE </div>
<div> TXT </div>
</td></tr>
</table>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top