5 replies [Last post]
Str187
Offline
newbie
Istanbul
Last seen: 7 years 15 weeks ago
Istanbul
Joined: 2007-07-23
Posts: 2
Points: 0

hi all this is my first post here =) i hope i'll find an answer...

how can i make an image appear when i move the cursor on a text...i searched but couldnt find an exact answer.

thanks =) Smile

mofo5000
Offline
newbie
uk
Last seen: 7 years 17 weeks ago
uk
Joined: 2007-07-23
Posts: 2
Points: 0

Hi Str187, This is basic

Hi Str187,

This is basic but should be what your looking for. I have put comments against each CSS bit to help you out. If you want to learn how to edit these and or add you own you look here:

http://www.w3schools.com/css/css_reference.asp

To be honest it doesnt take longer than a month to get a good grip of CSS providing you already know a bit about HTML.

That said http://www.w3schools.com will teaches just about every aspect of web programming if your interested.



a.mytext
{
display: block;
width: 50px; height: 15px; /* you'll have to set the H/W to the H/W of you text*/
text-decoration: none; /* gets rid opf the old breadcrumbs*/
color: black; /* sets text color to black*/
background-color: transparent; /* speaks for itself*/
font: 11px verdana; /* sets font size then font style*/
}

a.mytext:hover
{
background-image: url('webimages/titles_BG.png'); /*change the filename to suit yours*/ background-repeat: no-repeat; /* prevents the image from repeating*/
width: 800px; height: 600px; /* change the H/W to suit the size of your image*/
border: 1px solid black;
}



You text here

Hope this helps,
Luke

Tyssen
Tyssen's picture
Offline
Moderator
Brisbane
Last seen: 5 weeks 5 days ago
Brisbane
Timezone: GMT+10
Joined: 2004-05-01
Posts: 8201
Points: 1386

Str187 wrote:how can i make

Str187 wrote:
how can i make an image appear when i move the cursor on a text

That depends. Where abouts on the page is the image s'posed to appear?

How to get help
Post a link. If you can't post a link, jsFiddle it.
My blog | My older articles | CSS Reference

Str187
Offline
newbie
Istanbul
Last seen: 7 years 15 weeks ago
Istanbul
Joined: 2007-07-23
Posts: 2
Points: 0

@mofo5000 actually this is

@mofo5000

actually this is not what i need =) all you do is changing the background using hover =)

@Tyssen

i want to see an image (in the same div with the text) when i move the cursor over the text...

anyway, i thank you both =)

Deuce
Deuce's picture
Offline
Guru
Las Vegas, NV
Last seen: 1 year 30 weeks ago
Las Vegas, NV
Timezone: GMT-5
Joined: 2005-11-20
Posts: 4422
Points: 1841

if you know how to edit code

if you know how to edit code you can look at www.idprojections.com/portfolio.php and see how i did it.

all ยป http://dictionary.reference.com/browse/all

Google isn't a bunch of guys reading and grading web sites, it's more like a bunch of monkeys sniffing food and putting the good bananas at the top. -Triumph

Nerthus
Offline
Regular
Norway
Last seen: 5 years 44 weeks ago
Norway
Timezone: GMT+2
Joined: 2007-07-18
Posts: 12
Points: 0

http://www.dynamicdrive.com/s

http://www.dynamicdrive.com/style/csslibrary/item/css-popup-image-viewer/

maybe you are looking for something like this? Smile

hover over the link sushi and zooka coffee and pics are showing.

/Nerthus