|
-
Sep 19th, 2012, 06:35 AM
#1
Thread Starter
Hyperactive Member
Help adding a "changed" callback function to existing plugin (not written by me)
Hi,
My jQuery skills are not that wonderful, and wanted to ask if someone can help me modify this plugin.
Basically I need to be able to specify a callback event that need to be fired after line 56.
Code:
preview.html('<img src="' + e.target.result + '" ' + (preview.css('max-height') != 'none' ? 'style="max-height: ' + preview.css('max-height') + ';"' : '') + ' />');
The reason is that while this plugin works fantastic, the moment a new image are loaded in the the "preview" div, I need to apply a jCrop call to it (which is the next step)
Pretty please...been swearing the better part of the afternoon here.
For what it matter, here's a demo calling the plugin : http://jasny.github.com/bootstrap/ja...tml#fileupload
-
Nov 9th, 2012, 07:41 PM
#2
Hyperactive Member
Re: Help adding a "changed" callback function to existing plugin (not written by me)
Trigger Event:
$('body').trigger("SOME_EVENT");
Listener:
$('body').bind("SOME_EVENT", function(){
alert('triggered');
});
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|