Javascript Create custom callback
<p>All i need to do is to execute a callback function when my current function execution end</p>

<pre><code>function LoadData() 
{
    alert('the data have been loaded');
    //call my callback with parameters i want Ex.
    //callback(loadedData , currentObject);
}
</code></pre>

<p>Consumer for this function should be like this </p>

<pre><code>object.LoadData(success);

function success(loadedData , currentObject) 
{
  //todo some action here 
}
</code></pre>

<p>So how to implement this</p>
