Last item clicked

I have a menu and I need to know the last menu item clicked. So if I click on menu item 1 and then click on menu item 2, I need to know that menu item 1 was the last item clicked. Is there a simple javascript function that will do this? :expressionless: