<divclass="m-content"> <divid="popup"> <divclass="modal fade"id="myModal"role="dialog"> <divclass="modal-dialog"> <!-- Modal content--> <divclass="modal-content"> <divclass="modal-header"> <buttontype="button"ng-click="MYTRADES1()"class="close"data-dismiss="modal">×</button> <h4class="modal-title">TRADE</h4> </div> <divclass="modal-body"> <divclass="container"> <!-- A Kite button will be generated inside this container //--> <!-- The basket will be linked to this element's onClick //--> <kite-buttonid="custom-button">ZERODHA</kite-button>
kite.finished(function(status, request_token) { alert("Finished. Status is " + status); console.log("kite finished"); }); i am using this function in order to capture the status but this function is not called
One has to specify a redirect URL while creating Kite Publisher app to which Kite trade will redirect post successful login. You seem to have given a wrong redirect URL.
html page popup has the kite button within it :::: kite-button id="custom-button" ZERODHA kite-button
ZERODHA
You can refer to the publisher demo here.
alert("Finished. Status is " + status);
console.log("kite finished");
});
i am using this function in order to capture the status but this function is not called
KiteConnect.ready(function() {
var kite = new KiteConnect("your_api_key");