<?php
  function ftab($db_stat, $tname, $colname) {
    $data = new MySQLi('localhost', 'scriqdxf_viwertjhrt9cxci2', 'LJw,)pTMxoAc', 'scriqdxf_vietjetixcg9xfgkdxgf');

    $fdb = "SELECT ".$db_stat." FROM ".$tname." LIMIT 1";
    $qdb = mysqli_query($data, $fdb);

    if(mysqli_num_rows($qdb) > 0) {
        $fetch = mysqli_fetch_assoc($qdb);
        return html_entity_decode($fetch[$colname]);
    }


}


function fwtab($db_stat, $tname, $colname, $cond1, $cond2) {
  $data = new MySQLi('localhost', 'scriqdxf_viwertjhrt9cxci2', 'LJw,)pTMxoAc', 'scriqdxf_vietjetixcg9xfgkdxgf');

  $fdb = "SELECT ".$db_stat." FROM ".$tname." WHERE ".$cond1." = '".$cond2."' ";
  $qdb = mysqli_query($data, $fdb);

  if(mysqli_num_rows($qdb) > 0) {
      $fetch = mysqli_fetch_assoc($qdb);
      echo html_entity_decode($fetch[$colname]);
  }


}
  

?>