somewhere in my application I get a formatted html from server to be displayed to user:
me.myPanel().update(response.responseText);
Now, I want to put in this html some links (like “add comment”) in every record. I get this in the server!
But how to capture this links in extjs to act like a button or so ?
I would use a delegate for this.
In the code above you would have a couple of < a > tags in the body of your panel.
delegatewill make sure that the click only applies to your a tags with only linkclass on them.Here’s a fiddle: http://jsfiddle.net/N9MSC/