Clicking image to change variable

I'm still pretty new to rails but I've got a lot of the basic stuff working.

On one page I have a set of images, and I'd like to make it so that clicking them will change a variable I have. Is there a simple method for mouse click on object triggers -> do something? I'm still learning all the available commands.

Thanks

I'm still pretty new to rails but I've got a lot of the basic stuff working.

On one page I have a set of images, and I'd like to make it so that clicking them will change a variable I have. Is there a simple method for mouse click on object triggers -> do something? I'm still learning all the available commands.

Look into link_to_function (if it's all client side) or link_to_remote.

-philip

Philip Hallstrom wrote:

Look into link_to_function (if it's all client side) or link_to_remote.

-philip

That should work. Thanks