I followed the instructions in all the docs (at least I think) and I sort of have something working but have a problem with my reference
I use this to add to my linkbutton
Me.lbSubscribe.Attributes.Add("onclick", DotNetNuke.UI.Utilities.ClientAPI.GetCallbackEventReference(Me, "'test'", "successFunc", "'" & Me.lblSubscribe.ClientID.ToString & "'", "errorFunc"))
And this works up to a point
for testing I use this JS
<script>
function successFunc(result,ctx)
{
alert('recieved:' + result + '(' + ctx.id + ')');
//change pic here
}
function errorFunc(result,ctx)
{
alert('failed:' + result + '(' + ctx.id + ')');
}
</script>
however I never see ctx.id I always get an undefined - I asssume (unless I misread) that the ctx.id would be the clientid of the linkbutton - what might I be doing wrong here?