也許這個問題是如此基本,我無法找到它解釋。從php獲取%的百分比與php
我有一個2值的表。說明|從mysql中迴盪的估值。 我正在尋求獲取指示的百分比值(%)作爲估值。 即10個約會/ 5個銷售= 50%的轉換率。 總和將銷售/任命x 100 =%
任何想法如何將這個回聲到我的html表''百分比'列?
$query = "SELECT * FROM office_figures2016";
$result = mysqli_query($conn, $query);
while($office_figures2016=mysqli_fetch_assoc($result)){
echo "<tr>";
//changes date to english format from a time stamp
echo"<td>".$office_figures2016['id_why']."</td>";
echo"<td>".date('d-m-Y',strtotime($office_figures2016['date_figures']))."</td>";
echo"<td>".$office_figures2016['valuations']."</td>";
echo"<td>".$office_figures2016['instructions']."</td>";
echo"<td>".$office_figures2016['percentage of above']."</td>";
[MySQL Calculate Percentage]可能重複(https://stackoverflow.com/questions/15746749/mysql-calculate-percentage) – Sand
你有你需要的一切,你知道計算是什麼,那麼究竟是什麼問題 – RiggsFolly
我想你要找的答案是[here](https:// stacko verfusion.com/questions/15746749/mysql-calculate-percentage) – Sand