1 Hour
6 Hours
24 Hours
30 days
90 days
12 months
This Year
Last Year
฿
Sell Bitcoins ...
Buy Bitcoins ...
", 1);
$.ajax({
method: "POST",
url: req_url,
data: { nonce: nonce, userid: "", token: md5("" + day_of_y), signature: md5( "" + nonce + "" + command + cur_currency1 + cur_currency2 + $("#box_trade_amount").val() + $("#box_trade_price").val() ) },
cache: false
})
.done(function( ajax__result ) {
var processed = 0;
var error_message = "Order has been declined.";
try
{
var arr_ajax__result = JSON.parse(ajax__result);
if ( arr_ajax__result["success"] ) {
processed = 1;
}
else {
if (typeof arr_ajax__result["message"] !== "undefined" && arr_ajax__result["message"].length > 0)
error_message = arr_ajax__result["message"];
}
if ( typeof refresh_box_user_trades === "function" )
refresh_box_user_trades();
}
catch(error){}
if (processed) {
show_message_box_box("Success", "Your order has been accepted.", 1);
if ( typeof refresh_balance === "function" )
refresh_balance();
}
else {
show_message_box_box("Error", error_message, 2);
}
});
}
$(function() {
$("#box_trade_price").click(function() {
validate_obj("box_trade_amount");
});
$("#box_trade_total").click(function() {
validate_obj("box_trade_amount");
validate_obj("box_trade_price");
});
});