Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Mar 2009
    Posts
    14
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Problem adding java script to php fusion...

    Hello,
    there is one script that i have problem to implement to php fusion site,
    the code have to make when mouse is over menu in separate table is shown latest content
    of my site,

    can you please tell me exactly how to add it and in which files
    i have to add it , there are one java code:

    <
    Code:
    script type="text/javascript">
    function news(n) {
        if (n == "games")
            document.getElementById("news").innerHTML = "Yay, games!";
        else if (n == "soft")
            document.getElementById("news").innerHTML = "Yay, software!";
        else if (n == "other")
            document.getElementById("news").innerHTML = "Yay, other stuff!";
    }
       
    </script>
    and one html code:

    Code:
    <ul>
        <li><a href="" onmouseover="news('games')"/>Games</li>
        <li><a href="" onmouseover="news('soft')"/>Software</li>
        <li><a href="" onmouseover="news('other')"/>Other</li>
        </ul>
      <div id="news">
    </div>;

    Thank you in advance.
    Last edited by gigax; 03-10-2009 at 10:41 PM.

  • #2
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    That code looks like it should work, although it is Javascript and therefore belongs in the Javascript forum... so... what was your question?


  •  

    Posting Permissions

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