Turns out the problem was with 'var'.

Changed 'clickedItem = this;' to 'var clickedItem = this;' solved my
problem. I'm going to have to read up on var, it was my understanding that
using var within a function made it local. Hmmm... ??



sinkingfish wrote:
> 
> I'm doing some ajax image uploads using the plugin at valums.com (thanks).
> 
> I have multiple images on the page which I will be replacing with the
> uploaded image. My problem is this, trying to refer to the clicked image
> within the onComplete function.
> 
> I tried creating a variable that refered to 'this' which I beleive to be
> the image element but when I make the change to the element it is not
> refected, making me think that the variable is a copy and not a reference
> ?
> 
> I've pasted here for you to have a peak.
> http://pastie.org/524221
> 
> Thanks 
> 
> Brian
> 

-- 
View this message in context: 
http://www.nabble.com/Ajax-uplaod-tp24203971s27240p24206367.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.

Reply via email to