三级分销提成计算器

 

目前已经把代码放到网站上了

 

在线版三级分销提成计算器:http://www.yifei100.com/services/fenxiao-calc.html

 

代码:


php /* * @author Lmy * QQ:6232967 * Create at 2016-3-16 15:27:20 */ error_reporting(E_ALL); if(isset($_GET['act']) && $_GET['act']){ $level1Money = $_POST['level1Money']; $level2Money = $_POST['level2Money']; $level3Money = $_POST['level3Money']; if($_GET['act'] == 'normal'){ $level1People = $_POST['level-people']; $level2People = $level1People * $level1People; $level3People = $level1People * $level1People * $level1People; $level1_total = $level1Money * $level1People; $level2_total = $level2Money * $level2People; $level3_total = $level3Money * $level3People; $total_people = $level1People + $level2People + $level3People; $total = $level1_total + $level2_total + $level3_total; }else if ($_GET['act'] == 'custom') { $level1People = $_POST['level1']; $level2People = $_POST['level2']; $level3People = $_POST['level3']; $level1_total = $level1Money * $level1People; $level2_total = $level2Money * $level2People; $level3_total = $level3Money * $level3People; $total_people = $level1People + $level2People + $level3People; $total = $level1_total + $level2_total + $level3_total; }else{ } } ?> 三级分销提成计算器
class="container">
class="row">
class="col-xs-12">
class="panel panel-success">
class="panel-heading">简单计算
class="panel-body">
class="form-inline" action="?act=normal" method="post">
class="row">
class="col-xs-12">
class="form-group"> class="form-control" id="level1Money" value="200" placeholder="请输入金额">
class="form-group"> class="form-control" id="level2Money" value="60" placeholder="请输入金额">
class="form-group"> class="form-control" id="level3Money" value="30" placeholder="请输入金额">
class="col-xs-12">
class="form-group"> class="form-control" id="level-people" placeholder="每级裂变人数">
class="col-xs-12">
class="panel panel-success" style="display: none;">
class="panel-heading">定制计算
class="panel-body">
class="form-inline" action="?act=custom" method="post">
class="row">
class="col-xs-12">
class="form-group"> class="form-control" id="exampleInputName2" value="200" placeholder="请输入金额">
class="form-group"> class="form-control" id="exampleInputEmail2" value="60" placeholder="请输入金额">
class="form-group"> class="form-control" id="exampleInputEmail3" value="30" placeholder="请输入金额">
class="col-xs-12">
class="form-group"> class="form-control" id="exampleInputName4" placeholder="请输入人数">
class="form-group"> class="form-control" id="exampleInputEmail5" placeholder="请输入人数">
class="form-group"> class="form-control" id="exampleInputEmail6" placeholder="请输入人数">
class="col-xs-12">
if(isset($_GET['act']) && $_GET['act']){ ?>
class="panel panel-info">
class="panel panel-heading">计算结果
class="panel-body">
class="row">
class="col-xs-6"> 一级人数:$level1People; ?>
class="col-xs-6"> 提成:$level1_total; ?>
class="col-xs-6"> 二级人数:$level2People; ?>
class="col-xs-6"> 提成:$level2_total; ?>
class="col-xs-6"> 三级人数:$level3People; ?>
class="col-xs-6"> 提成:$level3_total; ?>
class="col-xs-12"> 总人数:$total_people; ?>
class="col-xs-12"> 总提成:$total; ?>

 

转载于:https://www.cnblogs.com/james888/p/5825848.html

你可能感兴趣的:(三级分销提成计算器)