html img returned from ajax has class of 'tocrop'. Currently I Calling the function on the success of the ajax call:
$("#imageform").ajaxForm({
target: '#image_upload_preview',
success: jcropp(),
})
function jcropp(){
$('.tocrop').Jcrop();
}
I have tried using .load(), setInterval() and clearInterval(when $('.tocrop').Jcrop()), .bind() to bind a function after it has loaded...nothing seems to work
There has already been a thread on this but the solutions did not work
Any help would be greatly appreciated This is being returned from server, have already tried binding $('.tocrop').load()to jcrop function:
<img class='tocrop' src='/tempupload/".$upload_data['file_name']."'/>