Código HTML:
Ver original- <img onclick="big_img(this);" id="img-p" src='$1' title="Click para ver"> 
Código Javascript
:
Ver original- function big_img(img){ 
-       if(img.style.maxWidth=="400px"){ 
-       img.style.maxWidth="120px"; 
-       }else{ 
-       img.style.maxWidth="400px"; 
-       } 
-       
-   
-       } 
Código idéntico, pero usando "this". 
PD. Releyendo, ésto ya te lo han dicho.