shadowayex Posted March 31, 2008 Share Posted March 31, 2008 I'm making a weapon chart for a game and I want to use the onmouseover function to make a little description box pop up. Kind of like you can set picture links to have a description thing using the alt="" attribute. How would I do that? By the way, the chart is in a table so I was gonna put the onmouseover in the <td> tags. Link to comment Share on other sites More sharing options...
justsomeguy Posted March 31, 2008 Share Posted March 31, 2008 Check here:http://www.walterzorn.com/tooltip/tooltip_e.htm Link to comment Share on other sites More sharing options...
shadowayex Posted March 31, 2008 Author Share Posted March 31, 2008 I read through that. It gives a js page that you use. That's not quite that helpful because of the massive number of weapons and stuff. I wanted to make a function for each in a separate js file and have it called, but I tried looking through their code and seeing what I could take and use and I can't decipher it. Link to comment Share on other sites More sharing options...
justsomeguy Posted April 1, 2008 Share Posted April 1, 2008 That's what you need to use, you only include that file once. Each tag that you want a tooltip to appear on you use an onmouseover event to add the tooltip. e.g.:<a href="index.htm" onmouseover="Tip('Some text')" onmouseout="UnTip()">Homepage </a>That's a whole lot better then having a separate function for each item you want a tooltip to show up on. Link to comment Share on other sites More sharing options...
shadowayex Posted April 1, 2008 Author Share Posted April 1, 2008 Sounds good I guess. I understand how to use it, I just wanted to keep my main file as small as possible by storing the info outside of the page. But this will do. Link to comment Share on other sites More sharing options...
justsomeguy Posted April 1, 2008 Share Posted April 1, 2008 It doesn't matter if you remove the info from one place to keep it in another place, the browser will still have to download everything. In fact, it will take less time to download if it's all in one place because of less overhead on the requests. Link to comment Share on other sites More sharing options...
shadowayex Posted April 1, 2008 Author Share Posted April 1, 2008 Oh. Makes sense I suppose. Thanks for your help. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.