Jump to content


Photo

Can I?


  • Please log in to reply
5 replies to this topic

#1 valentin

valentin
  • New Members
  • Pip
  • Newbie
  • 6 posts

Posted 16 July 2006 - 04:29 PM

Can I write in PHP a function similar to onmouseover. For example I have an image and I want to show a small dialog box (in which I should be able to write "this is my image") whenever the mouse is over it. I have seen this done with javascript, but I don't know this script, yet. That is why I am asking you if it can be done only with PHP (HTML).
Thank you in anticipation!

#2 Kurt

Kurt
  • Members
  • PipPipPip
  • Advanced Member
  • 42 posts
  • LocationNew York

Posted 16 July 2006 - 04:31 PM

I don't think it can be done with php...

#3 AndyB

AndyB
  • Staff Alumni
  • Advanced Member
  • 5,465 posts
  • LocationToronto

Posted 16 July 2006 - 04:39 PM

I'm sure it can't be done.  What you're looking for is browser behaviour that occurs on the client machine, whereas php executes only on the server and then sends the results to the browser.

The standard html attributes title and alt work with images. Simple is best.
Legend has it that reading the manual never killed anyone.
My site

#4 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 16 July 2006 - 04:44 PM

You wont be able to do this PHP alone, but with AJAX you will be able to. AJAX allows to to use Javascript with PHP. There are a few ajax tutorials over at http://www.ajaxfreaks.com to understand how to use AJAX

#5 valentin

valentin
  • New Members
  • Pip
  • Newbie
  • 6 posts

Posted 16 July 2006 - 04:46 PM

Ok, thank you! I will ckeck this AJAX out!

#6 cmgmyr

cmgmyr
  • Members
  • PipPipPip
  • Advanced Member
  • 1,278 posts
  • LocationUSA

Posted 16 July 2006 - 05:22 PM

You can also check out Sweet Titles at http://www.dustindiaz.com/download/ it basically takes whatever you have in the title atribute of a link or image and displays a nice little box.

-Chris




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users