WordPress.org

Forums

php in javascript mouse-over (1 post)

  1. Please Add Screenshots
    Member
    Posted 3 years ago #

    I'm trying to incorporate an image via php (custom field) inot a javascript mouse-over thingy

    Can anyone help me out here?

    Thanks
    Pete

    <img src='http://s.wordpress.com/mshots/v1/http%3A%2F%2F<?php echo get_post_meta($post->ID, "website1", true); ?>?w=300'
    onmouseover="this.src='http://perthmetro.net/wp-content/uploads/electrician1.jpg'"
    onmouseout="this.src='http://perthmetro.net/wp-content/uploads/newborn-photography-02-300x194.jpg'"/>

Topic Closed

This topic has been closed to new replies.

About this Topic

  • RSS feed for this topic
  • Started 3 years ago by Please Add Screenshots
  • This topic is not resolved
  • WordPress version: 3.4.1