emprit

sort

Dec 15th, 2012
132
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.98 KB | None | 0 0
  1. <link rel="stylesheet" type="text/css" href="<?php echo base_url();?>css/tabel.css">
  2. <body>
  3.  
  4. <table id="hor-minimalist-b" class="table-overview">
  5. <tbody>
  6. <tr>
  7. <th scope="col">No.</th>
  8. <th scope="col">No. Urut Pelamar</th>
  9. <?php
  10.  
  11. foreach($krit as $row){
  12. echo "<th scope='col'>$row->kriteria</th>";
  13. }
  14. ?>
  15. <th scope="col">Hasil Akhir</th>
  16. <th scope="col">Rangking</th>
  17. </tr>
  18.  
  19. <tr>
  20. <?php
  21. $no = 1;
  22. foreach($no_urut as $row1){
  23.     echo "<tr>";   
  24.     echo "<td>$no</td>";
  25.     echo "<td>GE_".$row1->no_urut."</td>";
  26.     $num = $row1->no_urut;
  27.                 $jum = 0;
  28.                 foreach($krit as $row){
  29.                     $id = $row->id_kriteria;   
  30.                     $nn = $row1->{"nilai_$id"};
  31.                     $nnn = $row->nilai/100*$nn;
  32.                     echo "<td><center>".$nnn."<center></td>";
  33.                     $data_fix[$row->kriteria] = $nnn;
  34.                    
  35.                    
  36.                     $jum+=$nnn;
  37.                 }
  38.                
  39.                 echo "<td>$jum</td>";
  40.                 $data_fix['hasil_akhir'] = $jum;
  41.                 echo "<pre>".var_dump($data_fix)."</pre>";
  42.                
  43.     echo "</tr>";  
  44.    
  45.     $no++;     
  46.     }
  47.    
  48. ?>
  49.  
  50. </table>
Advertisement
Add Comment
Please, Sign In to add comment