当前位置: 首页>>代码示例>>PHP>>正文


PHP satoshitize函数代码示例

本文整理汇总了PHP中satoshitize函数的典型用法代码示例。如果您正苦于以下问题:PHP satoshitize函数的具体用法?PHP satoshitize怎么用?PHP satoshitize使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了satoshitize函数的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: satoshitize

?>
</td>
               </tr><tr>
                  <td align="right" nowrap><b>Sub-total</b></td>
                  <td align="right" nowrap><font id="sell-subtotal"><?php 
$ssubtotal = 0 * $Buying_Rate;
echo satoshitize($ssubtotal);
?>
</font></td>
                  <td align="left" nowrap><?php 
echo $BTC;
?>
</td>
               <?php 
$sfee = $ssubtotal / 100 / 5;
$sfee = satoshitize($sfee);
if ($my_coins->coins[$BTCS]["sell_fee"] == true) {
    echo '
			   </tr><tr>
                  <td align="right" nowrap><b>Fee</b></td>
                  <td align="right" nowrap><font id="sell-fee">' . $sfee . '</font></td>
                  <td align="left" nowrap>' . $BTC . '</td>
			   ';
} else {
    echo '<input id="sell-fee" type="hidden" value="0">';
}
?>
               </tr><tr>
                  <td colspan="3" style="height: 10px;"></td>
               </tr><tr>
                  <td colspan="3" align="right" nowrap><input type="submit" value="Sell" onmouseenter="sellcalculator();" class="sellbutton"></td>
开发者ID:GeopaymeEE,项目名称:bitcoinexchange-final,代码行数:31,代码来源:index.php

示例2: satoshitize

               </tr><tr>
                  <td align="right" nowrap><b>Sub-total</b></td>
                  <td align="right" nowrap><font id="sell-subtotal"><?php 
$bsubtotal = 0 * $Buying_Rate;
echo satoshitize($bsubtotal);
?>
</font></td>
                  <td align="left" nowrap><?php 
echo $BTC;
?>
</td>
               </tr><tr>
                  <td align="right" nowrap><b>Fee</b></td>
                  <td align="right" nowrap><font id="sell-fee"><?php 
$sfee = $ssubtotal / 100 / 5;
echo satoshitize($sfee);
?>
</font></td>
                  <td align="left" nowrap><?php 
echo $BTC;
?>
</td>
               </tr><tr>
                  <td colspan="3" style="height: 10px;"></td>
               </tr><tr>
                  <td colspan="3" align="right" nowrap><input type="submit" value="Sell" onmouseenter="sellcalculator();" class="sellbutton"></td>
               </tr>
            </table>
         </td>
      </tr><tr>
         <td align="left" valign="top" style="padding: 5px;" nowrap>
开发者ID:blackchat,项目名称:BitcoinExchange,代码行数:31,代码来源:index.php

示例3: satoshitrim

        $Orders_Sells_Rate = $Row['rate'];
        $Orders_Sells_Total = $Orders_Sells_Amount * $Orders_Sells_Rate;
        $Orders_Sells_Total = satoshitrim(satoshitize($Orders_Sells_Total));
        $Sells_td .= '<tr>
                       <td align="right" style="padding: 1px;" nowrap><a href="#" onclick="setbuyamounts(' . $Orders_Sells_Amount . ');">' . $Orders_Sells_Amount . '</a></td>
                       <td align="right" style="padding: 1px; padding-left: 10px;" nowrap><a href="#" onclick="setbuyrates(' . $Orders_Sells_Rate . ');">' . $Orders_Sells_Rate . '</a></td>
                       <td align="right" style="padding: 1px; padding-left: 10px;" nowrap>' . $Orders_Sells_Total . '</td>
                    </tr>';
    }
    $buy_subtotal = "0";
    $Query = mysql_query("SELECT amount FROM sell_orderbook WHERE want='" . $my_coins->coins_names_prefix[2] . "' and trade_id='" . $my_coins->getTradeId() . "' and processed='1' ORDER BY rate ASC");
    while ($Row = mysql_fetch_assoc($Query)) {
        $buy_amount = $Row['amount'];
        $buy_subtotal += $buy_amount;
    }
    $cncvalue = satoshitrim(satoshitize($buy_subtotal));
    echo '<table>
               <tr>
                  <td colspan="4" align="left" style="font-weight: bold; padding: 2px;" nowrap>Sell Orders</td>
               </tr><tr>
                  <td colspan="4" align="right" style="padding: 2px;" nowrap>Total ' . $my_coins->coins_names_prefix[1] . ': ' . $cncvalue . '</td>
               </tr><tr>
                  <td align="left" style="font-weight: bold; padding: 1px;" nowrap>Amount (' . $my_coins->coins_names_prefix[1] . ')</td>
                  <td align="left" style="font-weight: bold; padding: 1px; padding-left: 10px;" nowrap>Rate (' . $my_coins->coins_names_prefix[2] . ')</td>
                  <td align="left" style="font-weight: bold; padding: 1px; padding-left: 10px;" nowrap>Total (' . $my_coins->coins_names_prefix[2] . ')</td>
               </tr>' . $Sells_td . '</table>';
} else {
    echo '<table style="width: 260px;">
            <tr>
               <td align="left" style="font-weight: bold; padding: 2px;" nowrap>Sell Orders</td>
            </tr><tr>
开发者ID:afrikanhut,项目名称:bitcoinexchange-final,代码行数:31,代码来源:sellorders-BTCRYX.php

示例4: header

    if ($iid != $my_coins->getSelectInstanceId()) {
        header("Location: home.php");
    }
}
$iid = $my_coins->getSelectInstanceId();
$cid = $my_coins->getCoinsSelectInstanceId() + 1;
if ($withdraw_withdraw == "withdraw") {
    if ($withdraw_address) {
        if ($withdraw_amount) {
            $withdraw_amount = satoshitize($withdraw_amount);
            if ($withdraw_amount <= $Bitcrystald_Balance[$iid]) {
                $fee = $my_coins->coins[$my_coins->coins_names[$cid]]["fee"];
                $FEEBEE = $my_coins->coins[$my_coins->coins_names[$cid]]["FEEBEE"];
                $set_withdraw_amount = $withdraw_amount - $fee;
                // minus the fee
                $true_withdraw_amount = satoshitize($set_withdraw_amount);
                $Bitcrystald_Withdraw_From = $Bitcrystald[$iid]["daemon"]->sendtoaddress($withdraw_address, (double) $true_withdraw_amount);
                if ($Bitcrystald_Withdraw_From) {
                    $result = minusfunds($user_session, $my_coins->coins_names_prefix[$cid], $withdraw_amount);
                    $result = plusfunds($FEEBEE, $my_coins->coins_names_prefix[$cid], $fee);
                    // add fee to feebee account
                    $Bitcrystald_Balance = userbalance($user_session, $my_coins->coins_names_prefix[$cid]);
                    $withdraw_message = '<a href="#' . $Bitcrystald_Withdraw_From . '" target="_blank" style="color: #0B2161;">Withdraw was sent!<br>' . $Bitcrystald_Withdraw_From . '</a>';
                    if (!mysql_query("INSERT INTO transactions (id,date,username,action,coin,address,txid,amount,trade_id) VALUES ('','{$date}','{$user_session}','withdraw','" . $my_coins->coins_names_prefix[$cid] . "','{$withdraw_address}','{$Bitcrystald_Withdraw_From}','{$withdraw_amount}','" . $my_coins->getTradeId() . "')")) {
                        $eereturn_error = "System error.";
                    } else {
                        $eereturn_error = "Logged in.";
                    }
                }
            } else {
                $withdraw_message = 'You do not have enough ' . $my_coins->coins_names[$cid] . 's!';
开发者ID:GeopaymeEE,项目名称:bitcoinexchange-final,代码行数:31,代码来源:fundsbtcry.php

示例5: header

<?php

require_once 'auth.php';
if ($Logged_In !== 7) {
    header("Location: index.php");
}
$new_address = addslashes(strip_tags($_GET['newaddr']));
if ($new_address == "go") {
    $Bytecoind_accountaddress = $Bytecoind->getnewaddress($wallet_id);
    header("Location: index.php");
}
$withdraw_amount = addslashes(strip_tags($_POST['amount']));
$withdraw_address = addslashes(strip_tags($_POST['address']));
if ($withdraw_address) {
    if ($withdraw_amount) {
        $withdraw_amount = satoshitize($withdraw_amount);
        if ($withdraw_amount < $Bytecoind_Balance) {
            $Bytecoind_Withdraw_From = $Bytecoind->sendfrom($wallet_id, $withdraw_address, (double) $withdraw_amount, 6);
            $withdraw_message = $Bytecoind_Withdraw_From;
            $Bytecoind_Balance = $Bytecoind->getbalance($wallet_id, 6);
        } else {
            $withdraw_message = 'You do not have enough Bytecoins!';
        }
    } else {
        $withdraw_message = 'No amount to withdraw was entered!';
    }
}
?>
<html>
<head>
   <title>Bytecoin Wallet</title>
开发者ID:iamraghavgupta,项目名称:WalletScript,代码行数:31,代码来源:wallet.php

示例6: error_reporting

<?php

error_reporting(0);
$buy_subtotal = "0";
$buy_amounttotal = "0";
$Query = mysql_query("SELECT amount, rate FROM buy_orderbook WHERE want='" . $BTC . "' and trade_id='" . $my_coins->getTradeId() . "' and trade_with = '" . $BTCRYX . "' and processed='1' ORDER BY rate ASC");
while ($Row = mysql_fetch_assoc($Query)) {
    $buy_amount = $Row['amount'];
    $buy_rate = $Row['rate'];
    $buy_subtotal += $buy_amount * $buy_rate;
}
$btevalue = satoshitrim(satoshitize($buy_subtotal));
$buy_amounttotal = "0";
$Query = mysql_query("SELECT amount FROM sell_orderbook WHERE want='" . $BTC . "' and trade_id='" . $my_coins->getTradeId() . "' and trade_with = '" . $BTCRYX . "' and processed='1' ORDER BY rate ASC");
while ($Row = mysql_fetch_assoc($Query)) {
    $buy_amount = $Row['amount'];
    $buy_amounttotal += $buy_amount;
}
$btevolume = satoshitrim(satoshitize($buy_amounttotal));
echo '<table>
         <tr>
            <td nowrap>' . $BTCRYX . '/' . $BTC . '</td>
            <td style="padding-left: 10px;" nowrap>Volume ' . $btevolume . ' / ' . $btevalue . ' ' . $BTC . '</td>
         </tr>
      </table>';
开发者ID:afrikanhut,项目名称:bitcoinexchange-final,代码行数:25,代码来源:stats.php

示例7: satoshitize

</strong>! <?php 
if ($admin) {
    ?>
<strong><font color="red">[Admin]</font><?php 
}
?>
</strong>
<form action="index.php" method="POST">
<form>
        <input type="hidden" name="action" value="logout" />
        <button type="submit" class="btn btn-default"><strong>LOGOUT</strong></button>
</form>
</form>
</div>
<h2>Balance:<br/> <span class="counter" style="font-weight: bold; color:#0896FE;"><b><?php 
echo satoshitize($balance);
?>
</b></span> <?php 
echo $short;
?>
</h2>
<div class="sexytabs">
  <ul>
   <li><a href="#Withdraw">
      <span><b>Send </b></span></a></li>
    <li><a href="#Receive">
      <span><b>Receive</b></span></a></li>
    <li><a href="#Transactions">
      <span><b>Transactions</b></span></a></li>
     <li><a href="#Settings">
      <span><b>Settings</b></span></a></li>
开发者ID:Roverok,项目名称:wallet.moneta.io,代码行数:31,代码来源:wallet.php

示例8: minusfunds

function minusfunds($function_user, $function_coin, $function_amount)
{
    $found_value = false;
    for ($i = 0; $i < $GLOBALS['cp_count']; $i += 3) {
        $function_user_balance = userbalance($function_user, $function_coin);
        $function_balance = $function_user_balance - $function_amount;
        $function_balance = satoshitrim(satoshitize($function_balance));
        if ($function_coin == $GLOBALS['cp'][0 + $i]) {
            $sql = "UPDATE balances SET coin" . ($i + 1) . "='{$function_balance}' WHERE username='{$function_user}' AND trade_id = '" . getTradeId($i) . "'";
            $found_value = true;
        }
        if ($function_coin == $GLOBALS['cp'][2 + $i]) {
            $sql = "UPDATE balances SET coin" . ($i + 2) . "='{$function_balance}' WHERE username='{$function_user}' AND trade_id = '" . getTradeId($i) . "'";
            $found_value = true;
        }
        if ($function_coin == $GLOBALS['cp'][1 + $i]) {
            $sql = "UPDATE balances SET coin" . ($i + 3) . "='{$function_balance}' WHERE username='{$function_user}' AND trade_id = '" . getTradeId($i) . "'";
            $found_value = true;
        }
        if (!$found_value) {
            continue;
        }
        $result = mysql_query($sql);
        if ($result) {
            $function_return = "success";
        } else {
            $function_return = "error";
        }
        break;
    }
    return $function_return;
}
开发者ID:GeopaymeEE,项目名称:bitcoinexchange-final,代码行数:32,代码来源:functions_main.php

示例9: satoshitrim

    }
} else {
    echo '<option value="7">' . $buy_orderbook["message"] . '</option>';
}
?>
</select></td>
                  <td align="left" nowrap><?php 
echo $BTC;
?>
</td>
               </tr><tr>
                  <td align="right" nowrap><b>Sub-total</b></td>
                  <td align="right" nowrap><select id="sell-subtotal" name="order-total" size="1" onchange="changeIndexBuy('sell-subtotal');"><?php 
if ($count_buy_orderbook > 0) {
    for ($i = 0; $i < $count_buy_orderbook; $i++) {
        $value = satoshitrim(satoshitize($buy_orderbook["amount"][$i] * $buy_orderbook["rate"][$i]));
        echo '<option value="' . $value . '">' . $value . '</option>';
    }
} else {
    echo '<option value="8">' . $buy_orderbook["message"] . '</option>';
}
?>
</select></td>
                  <td align="left" nowrap><?php 
echo $BTC;
?>
</td>
               </tr><tr>
                  <td colspan="3" style="height: 10px;"></td>
               </tr><tr>
                  <td colspan="3" align="right" nowrap><input type="submit" value="Sell" class="sellbutton"></td>
开发者ID:afrikanhut,项目名称:bitcoinexchange-final,代码行数:31,代码来源:market.php

示例10: satoshitrim

        $Orders_Sells_Rate = $Row['rate'];
        $Orders_Sells_Total = $Orders_Sells_Amount * $Orders_Sells_Rate;
        $Orders_Sells_Total = satoshitrim(satoshitize($Orders_Sells_Total));
        $Sells_td .= '<tr>
                       <td align="right" style="padding: 1px;" nowrap><a href="#" onclick="setbuyamounts(' . $Orders_Sells_Amount . ');">' . $Orders_Sells_Amount . '</a></td>
                       <td align="right" style="padding: 1px; padding-left: 10px;" nowrap><a href="#" onclick="setbuyrates(' . $Orders_Sells_Rate . ');">' . $Orders_Sells_Rate . '</a></td>
                       <td align="right" style="padding: 1px; padding-left: 10px;" nowrap>' . $Orders_Sells_Total . '</td>
                    </tr>';
    }
    $buy_subtotal = "0";
    $Query = mysql_query("SELECT amount FROM sell_orderbook WHERE want='" . $BTC . "' and trade_id='" . $my_coins->getTradeId() . "' and trade_with = '" . $BTCRYX . "' and processed='1' ORDER BY rate ASC");
    while ($Row = mysql_fetch_assoc($Query)) {
        $buy_amount = $Row['amount'];
        $buy_subtotal += $buy_amount;
    }
    $btevolume = satoshitrim(satoshitize($buy_subtotal));
    echo '<table>
               <tr>
                  <td colspan="3" align="left" style="font-weight: bold; padding: 2px;" nowrap>Sell Orders</td>
               </tr><tr>
                  <td colspan="3" align="right" style="padding: 2px;" nowrap>Total ' . $BTCRYX . ': ' . $btevolume . '</td>
               </tr><tr>
                  <td align="left" style="font-weight: bold; padding: 1px;" nowrap>Amount (' . $BTCRYX . ')</td>
                  <td align="left" style="font-weight: bold; padding: 1px; padding-left: 10px;" nowrap>Rate (' . $BTC . ')</td>
                  <td align="left" style="font-weight: bold; padding: 1px; padding-left: 10px;" nowrap>Total (' . $BTC . ')</td>
               </tr>' . $Sells_td . '</table>';
} else {
    echo '<table style="width: 260px;">
            <tr>
               <td align="left" style="font-weight: bold; padding: 2px;" nowrap>Sell Orders</td>
            </tr><tr>
开发者ID:afrikanhut,项目名称:bitcoinexchange-final,代码行数:31,代码来源:sellorders.php

示例11: minusfunds

function minusfunds($function_user, $function_coin, $function_amount)
{
    $function_user_balance = userbalance($function_user, $function_coin);
    $function_balance = $function_user_balance - $function_amount;
    $function_balance = satoshitrim(satoshitize($function_balance));
    if ($function_coin == "BTC") {
        $sql = "UPDATE balances SET coin1='{$function_balance}' WHERE username='{$function_user}'";
    }
    if ($function_coin == "BTE") {
        $sql = "UPDATE balances SET coin2='{$function_balance}' WHERE username='{$function_user}'";
    }
    if ($function_coin == "LTC") {
        $sql = "UPDATE balances SET coin3='{$function_balance}' WHERE username='{$function_user}'";
    }
    $result = mysql_query($sql);
    if ($result) {
        $function_return = "success";
    } else {
        $function_return = "error";
    }
    return $function_return;
}
开发者ID:blackchat,项目名称:BitcoinExchange,代码行数:22,代码来源:functions_main.php


注:本文中的satoshitize函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。