SitePoint Sponsor

User Tag List

Results 1 to 8 of 8

Thread: changing test to an image

  1. #1
    Currently Occupied; Till Sunda Andrew-J2000's Avatar
    Join Date
    Aug 2001
    Location
    London
    Posts
    2,475
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    changing test to an image

    Does ne 1 have a script or a example,
    of how to make some
    text change to an image on a mouseover
    and
    another which changes an image to text
    etc,

    Thanx

  2. #2
    SitePoint Guru Vincent Puglia's Avatar
    Join Date
    Feb 2000
    Location
    where the World once stood
    Posts
    679
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi Andrew,

    No, I don't. However...

    Option 1: create an image with the desired text; then do a simple rollover -- onMouseOver="rollIt('textImg.jpg')"

    Option 2: use dHTML to change the contents of the div/layer from text to image. If you are unfamiliar with dHTML, see the introductory script/tutorial at my site and the Ryan article at PageResource

    hope this helps
    Vinny
    moderator at:Webxpertz Forums

  3. #3
    SitePoint Wizard creole's Avatar
    Join Date
    Oct 2000
    Location
    Nashvegas Baby!
    Posts
    7,845
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You could always use dHTML to accomplish this. Put the text in a layer and the image you want to become visible (on the rollover) in another layer. Hide the layer with the image, then write a javascript function that would hide the text layer and show the image layer at the same time.
    Adobe Certified Coldfusion MX 7 Developer
    Adobe Certified Advanced Coldfusion MX Developer
    My Blog (new) | My Family | My Freelance | My Recipes

  4. #4
    Currently Occupied; Till Sunda Andrew-J2000's Avatar
    Join Date
    Aug 2001
    Location
    London
    Posts
    2,475
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Thanx for your help

    I have not yet covered learning Javascript but
    I so far I haven't found any webmasters sites that
    cover this script,
    maybe it could be useful, for your content, as a webmaster,

    Ne way cheers for the help

  5. #5
    SitePoint Guru Vincent Puglia's Avatar
    Join Date
    Feb 2000
    Location
    where the World once stood
    Posts
    679
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi Andrew,
    You're welcome, but regarding:
    any webmasters sites that cover this script,
    I listed 2 == my own (GrassBlade) and PageResource/JavascriptCity

    If you read the 2 tutorial/scripts, you will be able to write your script with little to no help from others. It is unlikely anyone will have the exact script you want.

    Vinny
    moderator at:Webxpertz Forums

  6. #6
    Currently Occupied; Till Sunda Andrew-J2000's Avatar
    Join Date
    Aug 2001
    Location
    London
    Posts
    2,475
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Yes im looking at your site now

    Cheers, again,

    Nice site, by the way,

    I'm gonna have to learn JS, i just havent read up on how to yet, as im busy, so im gonna make a start soon,

    are there Ne books on DHTML, or Javascript that U would recommend, for more advanced, things,

  7. #7
    SitePoint Guru Vincent Puglia's Avatar
    Join Date
    Feb 2000
    Location
    where the World once stood
    Posts
    679
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi Andrew,

    Sorry I didn't get here sooner, but now that the codeRed virus is on its way out, I'll be spending less and less time here.

    RE:
    Nice site, by the way,
    Thank you

    Re books:
    for experienced programmers (javascript or otherwise):
    1) O'Reilly Publisher's Javascript the Definitive Guide by David Flanagan
    2) Danny Goodman's Javascript Bible

    for newbies:
    1) John Pollock of Javascript City just put one out -- link at his site
    2) "Javascript in 24 Hours"
    online:
    http://www.htmlgoodies.com

    Vinny
    moderator at:Webxpertz Forums

  8. #8
    Currently Occupied; Till Sunda Andrew-J2000's Avatar
    Join Date
    Aug 2001
    Location
    London
    Posts
    2,475
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Thanx

    Thanx

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •