• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.4 XML Help- Image Map

I am trying to set up an image map for my gallery so that when I click on the left 100 pixels it will go to the previous images and for the right 100 pixels it will go to next. I have the variables $image.height and $image.width at my disposal and the left side is working just fine.

The problems comes in on the right side because I can't figure out how to write a simple subtraction statement. I am editing a template, so it should be xml. I just want to be able to use a statement that would be the equivalent of {$image.width}-100. Any ideas?
Have you tried using xen:calc?

{xen:calc '{$image.width} - 100'}
That did it. Thanks. Now I'm working on another can of worms-- some of the images have been resized to be smaller and those, of course, cause this to break. So I need to figure out how to get the image width after the image has been resized.