Dan_Mason Posted January 6, 2010 Share Posted January 6, 2010 Hello I have used some Javascript to be able to switch between 3 generated graphs on a page. I wanted to do this so that the page didnt have to be refreshed every time a new graph was selected. All it is basically doing is switching between pictures, Here is a screenshot: All I really want to do is leave the last Hyperlink clicked highlighted, so that it is really obvious to the user which graph they are viewing! Any help would be much appreciated! Quote Link to comment Share on other sites More sharing options...
vinpkl Posted January 6, 2010 Share Posted January 6, 2010 are you using some server side script like php or static html for site. vineet Quote Link to comment Share on other sites More sharing options...
whansen02 Posted January 7, 2010 Share Posted January 7, 2010 You might run into some cross browser issues depending how you reference your html properties in javascript but that said the first thing I would think to do is use the OnClick function to call a function that applies highlighting to whatever html element was just clicked. The trick is un-highlighting a value once another is clicked - one way to do this would be to remember which one was last clicked, and set it back to normal when the next is clicked, since you're dealing with only 3 values it would be simpler to just say that the items that don't get clicked, all get set back to normal, the one that did get clicked gets set to highlighted by your custom php function. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.