GIF89a; CRX
KBHT HEHE
Server IP : 172.26.0.195  /  Your IP : 18.219.176.215
Web Server : Apache
System : Linux 43-205-77-33.cprapid.com 3.10.0-1160.119.1.el7.tuxcare.els2.x86_64 #1 SMP Mon Jul 15 12:09:18 UTC 2024 x86_64
User : jnclnmuac ( 1026)
PHP Version : 8.0.30
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /home/jnclnmuac/public_html/web/pdf/../../cas/application/views/admin/certificate/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/jnclnmuac/public_html/web/pdf/../../cas/application/views/admin/certificate/generateBC.php
<!DOCTYPE HTML>
<html>
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
        <title>Bonafide Certificate <?php echo $bcInfo['bc_sr_no']; ?> | College Automation System | <?php echo $this->session->userdata("adminData")["branch_short_name"]; ?></title>
        <link rel="stylesheet" href="<?php echo base_url("assets/admin/css/style.css"); ?>">
        <link rel="stylesheet" href="<?php echo base_url("assets/admin/css/jquery.dataTables.min.css"); ?>" type='text/css' />
        <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Nunito:300,400,600,700,800,900&amp;display=swap">
        <link rel="image icon" href="<?php echo base_url("assets/admin/images/logo.png"); ?>">
        <script src="<?php echo base_url("assets/admin/js/jquery-1.10.2.min.js"); ?>"></script>
        <script src="<?php echo base_url("assets/admin/js/bootstrap.min.js"); ?>"></script>
        <script src="<?php echo base_url("assets/admin/js/jquery.dataTables.min.js"); ?>"></script>
    </head>
    <body class="cbp-spmenu-push">
        <div class="se-pre-con"></div>
        <section>
            <?php $this->load->view("admin/navAndHeader"); ?>
            <div class="main-content">
                <div class="container-fluid content-top-gap">
                    <nav aria-label="breadcrumb">
                        <ol class="breadcrumb my-breadcrumb">
                            <li class="breadcrumb-item"><a href="<?php echo site_url("admin/Dashboard"); ?>">Home</a></li>
                            <li class="breadcrumb-item">Certificates</li>
                            <li class="breadcrumb-item active" aria-current="page"><a href="<?php echo site_url("admin/DocumentIssue/generateBC"); ?>">Issue Bonafide Certificate</a></li>
                        </ol>
                    </nav>
                    <section class="forms">
                        <div class="card card_border p-4">
                            <h3 class="card__title"><i class="fa fa-address-card-o"></i> Generate Student's Bonafide Certificate</h3><br>
                            <div class="card-body">
                                <?php if ($this->session->flashdata('successMessage')) { ?>
                                    <div class="alert alert-success alert-dismissible fade show"> 
                                        <strong><?php echo $this->session->flashdata('successMessage'); ?></strong> 
                                        <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                                            <span aria-hidden="true">&times;</span>
                                        </button>
                                    </div>
                                <?php } ?>
                                <?php if ($this->session->flashdata('errorMessage')) { ?>
                                    <div class="alert alert-danger alert-dismissible fade show"> 
                                        <strong><?php echo $this->session->flashdata('errorMessage'); ?></strong> 
                                        <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                                            <span aria-hidden="true">&times;</span>
                                        </button>
                                    </div>
                                <?php } ?>
                                <fieldset>
                                    <legend>Search Student <i class="fa fa-search"></i></legend>
                                    <?php echo form_open(site_url('admin/DocumentIssue/generateBC'), ['name' => 'studentSearchForBCFrm', 'id' => 'studentSearchForBCFrm']); ?>
                                    <div class="form-row">
                                        <div class="form-group col-md-12">
                                            <label class="input__label"><b>Search Pattern:</b></label>
                                            <input type="radio" class="" id="FNW" name="filterPattern" value="FNW" <?php echo set_radio("filterPattern", "FNW"); ?>>&nbsp;<label for="FNW">Form No. Wise</label>
                                            <input type="radio" class="" id="RNW" name="filterPattern" value="RNW" <?php echo set_radio("filterPattern", "RNW"); ?>>&nbsp;<label for="RNW">Enrl. No./Roll No. Wise</label>
                                        </div>
                                    </div>
                                    <div class="form-row">
                                        <div class="form-group col-md-4">
                                            <label for="stuFormNo" class="input__label">Form No</label>
                                            <input type="text" class="form-control" id="stuFormNo" name="stuFormNo" value="<?php echo set_value('stuFormNo'); ?>" placeholder="Enter Form No." autocomplete="off" maxlength="15" readonly="true">
                                        </div>
                                        <div class="form-group col-md-4">
                                            <label for="stuRollNo" class="input__label">Enrl. No./Roll No.</label>
                                            <input type="text" class="form-control" id="stuRollNo" name="stuRollNo" value="<?php echo set_value('stuRollNo'); ?>" placeholder="Enter Roll No." autocomplete="off" maxlength="20" readonly="true">
                                        </div>
                                        <div class="col-md-4">
                                            <label for="filterSubmitBtn" class="input__label"></label>
                                            <button id="previewSubmitBtn" name="previewSubmitBtn" type="submit" class="btn btn-lg btn-warning btn-block">Generate Bonafide Certificate&nbsp;<i class="fa fa-file"></i></button>
                                        </div>
                                    </div>
                                    <?php echo form_close(); ?>
                                    <hr>
                                </fieldset>
                                <?php
                                if ($bcInfo['is_bc_avail']) {
                                    ?>
                                    <div id="bcPreview" style="background: #FFF;">
                                        <table width="800" border="0" cellpadding="0" cellspacing="0" style="border:1px solid #000;" align="center">
                                            <tr> 
                                                <td width="3"></td>
                                                <td width="797" align="center" valign="top">
                                                    <table align="center" width="100%" border="0" cellpadding="0" cellspacing="0">
                                                        <tr> 
                                                            <td width="797" height="48" valign="top">
                                                                <table width="100%" border="0" cellpadding="0" cellspacing="0">
                                                                    <tr>
                                                                        <td width="797" height="120" align="center" valign="top"><img src="<?php echo base_url('assets/admin/images/header.png'); ?>" width="50%" height="100" style="margin-top:4%"></td>
                                                                    </tr>
                                                                </table>
                                                            </td>
                                                        </tr>
                                                        <tr> 
                                                            <td height="48" valign="top">
                                                        <center>
                                                            <p style="margin:5%;font-family: Courier;font-size: 15px;">
                                                            <h4 style="font-family:Times;"><b><u>TO WHOM TO SO EVER IT MAY CONCERN</u></b></h4>
                                                            </p>
                                                        </center>
                                                </td>
                                            </tr>

                                            <tr style="font-family: Arial;font-size:12px;"> 
                                                <td height="48" valign="top">
                                                    <table width="100%" border="0" cellpadding="0" cellspacing="0">
                                                        <tr>
                                                            <td width="797" height="25" valign="top">
                                                                <table width="100%" border="0" cellpadding="0" cellspacing="0">
                                                                    <tr>
                                                                        <td width="388" height="25" valign="middle">
                                                                            <span style="margin-left:5%"><b>&nbsp;No.:&nbsp;<?php echo $bcInfo['bc_sr_no']; ?>&nbsp;</b></span>
                                                                        </td>
                                                                        <td width="406" align="left"> 
                                                                            <span style="margin-left:65%"><b>Date:&nbsp;<?php echo $bcInfo['bc_date']; ?>&nbsp;</b></span>
                                                                        </td>
                                                                    </tr>
                                                                </table>
                                                            </td>
                                                        </tr>
                                                    </table>
                                                </td>
                                            </tr>
                                            <tr> 
                                                <td height="48" valign="top">
                                            <center>
                                                <h5 style="font-family:Times;"><b>BONAFIDE CERTIFICATE</b></h5>
                                            </center>
                                            </td>
                                            </tr>
                                            <?php
                                            if ($bcInfo['stu_gen'] == 'M') {
                                                $salutation = "Mr.";
                                                $pronoun1 = "He";
                                                $pronoun2 = "His";
                                                $sodo = "S/O";
                                            } else {
                                                $salutation = "Ms.";
                                                $pronoun1 = "She";
                                                $pronoun2 = "Her";
                                                $sodo = "D/O";
                                            }
                                            ?>
                                        </table>
                                        <table id="bc_content">
                                            <tr> 
                                                <td height="48" valign="top">
                                                    <p style="text-align: justify;margin-left: 5%;margin-right: 5%;color:#000;font-size: 20px;line-height: 50px;">
                                                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This is to certify that <b><?php echo $salutation; ?> <?php echo $bcInfo['stu_name']; ?> <?php echo $sodo; ?> <?php echo $bcInfo['stu_father_name']; ?></b> is a
                                                        bonafide student of <b><?php echo $bcInfo['stu_course_full_name']; ?>, <?php echo $bcInfo['stu_year_and_sem']; ?></b>.
                                                        <?php echo $pronoun2; ?> Enrl. No. is <b><?php echo $bcInfo['stu_enrollment_no']; ?></b> and Exam Roll No. is <b><?php echo $bcInfo['stu_rollno']; ?></b>.
                                                    </p>
                                                    <p style="text-align: justify;margin-left: 5%;margin-right: 5%;color:#000;font-size: 20px;line-height: 50px;">
                                                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<?php echo $pronoun1; ?> bears a good moral character.
                                                    </p>
                                                </td>
                                            </tr>
                                            <tr>
                                                <td align='right' colspan='3'><span style="margin-left:10%;margin-right:5%;font-family: Times;font-size:20px;"><b><i></i></b></span></td>
                                            </tr>
                                            <tr>
                                                <td align='right' colspan='3'><span style="margin-left:10%;margin-right:5%;font-family: Times;font-size:20px;"><b>Principal</b></span></td>
                                            </tr>
                                        </table>
                                        </table>
                                    </div>
                                    <br>
                                    <?php
                                    if (!$bcInfo['is_printable']) {
                                        echo form_open(site_url('admin/DocumentIssue/generateBC'), ['name' => 'studentIssueBCFrm', 'id' => 'studentIssueBCFrm']);
                                        ?>
                                        <input type="hidden" name="tspi_id" value="<?php echo $bcInfo['stu_id']; ?>">
                                        <input type="hidden" id="bc_content_html" name="bc_content_html">
                                        <button id="issueSubmitBtn" name="issueSubmitBtn" class="btn btn-sm btn-block btn-success" onClick="confirmBCIssue();">Issue Bonafide Certificate <i class="fa fa-check-circle"></i></button>
                                        <?php echo form_close(); ?>
                                    <?php } else { ?>
                                        <button id="printBtn" name="printBtn" class="btn btn-sm btn-block btn-warning" onClick="printBC();">Print Bonafide Certificate <i class="fa fa-print"></i></button>
                                            <?php
                                        }
                                    }
                                    ?>
                            </div>
                        </div>
                    </section>
                </div>
            </div>
        </section>
        <script>
            $("#FNW").on("click", function () {
                $("#stuRollNo").val("");
                $("#stuFormNo").prop("readonly", false);
                $("#stuRollNo").prop("readonly", true);
            });

            $("#RNW").on("click", function () {
                $("#stuFormNo").val("");
                $("#stuFormNo").prop("readonly", true);
                $("#stuRollNo").prop("readonly", false);
            });

            $(document).ready(function () {
                var selectedPattern = '<?php echo $selectedPattern; ?>';
                if (selectedPattern !== "") {
                    $("#" + selectedPattern).trigger("click");
                }
                if ('<?php echo $bcInfo['is_bc_avail']; ?>' === 1 || '<?php echo $bcInfo['is_bc_avail']; ?>' === '1') {
                    $("#bc_content_html").val($("#bc_content").html().trim());
                }
            });

            function confirmBCIssue() {
                if (confirm("After the system will issue bonafide certificate, you can take print or can save it as PDF.")) {
                    studentIssueBCFrm.submit();
                } else {
                    event.preventDefault();
                }
            }

            function printBC() {
                var divToPrint = document.getElementById("bcPreview");
                var newWin = window.open('', "Print-Window");
                newWin.document.open();
                newWin.document.title = '<?php echo $bcInfo['bc_sr_no']; ?>';
                newWin.document.write('<html><body onload="window.print()">' + divToPrint.innerHTML + '</body></html>');
                newWin.document.close();
                setTimeout(function () {
                    newWin.close();
                }, 10);
            }
        </script>
        <?php $this->load->view("admin/footer"); ?>
    </body>
</html>

KBHT - 2023