JQuery - How to identify previously selected buttons
<p>Scenario:</p>

<p>A simple html page exists with few buttons on Top (e.g. day, week) and BOTTOM (filter1 and filter2) of the page and Graph on center.</p>

<p>The graph displays a data based on selected filters.</p>

<p>Problem:</p>

<p>when user selects the filter2 I need to know what the user selected previously on TOP buttons so that the data can be displayed accordingly.</p>

<p>I'm using global variable to track the last selected buttons. This means lots of switch statements. I'm wondering if this is the most elegant way to solve this issue or is there any magic. function exist on Jquery.</p>
