<?php
    include_once("CUserSession.php");
    include_once("CUtil.php");
    include_once("CPayments.php");
    include_once("CPurchase.php");
    include_once("CProject_payment_validation.php");
     if(!isLoggedIn()){
        $url = split("payments.php",$_SERVER['REQUEST_URI']);
        header("Location: ".$url[0]."index.php");
        die();
    }
    // else{
    //     $project_id=$_GET["p"];
    //     if(!validate_and_navigate_payments($project_id)){ //verify if the project is valid and if payment is successful and navigate accordingly
    //         die();
    //     }
    // }
?> <!DOCTYPE html><html lang="en"><head><title>Payments - isUD™</title><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><meta http-equiv="x-ua-compatible" content="ie=edge"><meta name="description" content="innovative solutions for Universal Design(isUD™) offers resources and services to support and recognize adopters of universal design. isUD™ provides an interactive platform for browsing innovate solutions for UD, reference designs for designers and design resources that summarize the state of knowledge on a variety of topics related to UD."><meta name="keywords" content="inclusive design, universal design, accessibility, ada, barrier free design, wayfinding, anthropometry, design for all, diversity, wheelchair"><meta name="copyright" content="innovative solutions for Universal Design is a product of the University at Buffalo, Center for Inclusive Design and Environmental Access. All rights reserved."><meta name="dcterms.rightsHolder" content="The University at Buffalo, Center for Inclusive Design and Environmental Access."><meta property="og:title" content="Payments - isUD™"><meta property="og:description" content="isUD™ offers resources and services to support and recognize adopters of universal design. isUD™ provides an interactive platform for browsing innovate solutions for UD, reference designs for designers and design resources that summarize the state of knowledge on a variety of topics related to UD."><meta property="og:image" content="/images/isUD_PR_PublicTransit_Facebook.e6c1a408.png"><meta property="og:site_name" content="thisisUD"><meta property="og:image:width" content="470"><meta property="og:image:height" content="246"><link rel="Shortcut Icon" href="favicon.ico"><link rel="stylesheet" href="CSS/bootstrap.min.7cc40c19.css"><link rel="stylesheet" href="CSS/bootstrap-select.min.92f660cd.css"><link rel="stylesheet" href="CSS/intlTelInput.62d0a3f6.css"><link rel="stylesheet" href="CSS/custom.79b6d971.css"><link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css">      <style>
        table {
        font-family: arial, sans-serif;
        border-collapse: collapse;
        width: 100%;
        }

        td, th {
        border: 0px solid #dddddd;
        text-align: center;
        padding: 15px;
        font-size: 14px;
        }

        tr:nth-child(1) {
        background-color: #f9f9f9;
        }

        tr:nth-child(even) {
        background-color: #f9f9f9;
        }
        </style>
    </head>

    <body>
        <div class="cl-container cl-wrapper" id="id-wrapper">
            <?php
            if(!isLoggedIn()){ 
                Util::ScopedIncludeOnce("Banner.php", array('includerFile' => __FILE__));
            }else{
                Util::ScopedIncludeOnce("Banner_Login.php", array('includerFile' => __FILE__));
            }
        ?>
                <section id="id-global-container">
                    <div class="cl-div-width-container col-md-12">
                        <div class="tab-content">
                            <div class="active tab-pane">
                                <section>
                                    
                                    <div id="id-title-bar">
                                    <div id="id-project-title-text" class="cl-div-site-breadcrumb-static" style="font-size: 14px;">
                                        <span class="" style="font-size: 14px;"><a href="myProjects.php">My Projects</a> <a id="id-project-overview-bclink" href="#"> > Project Overview</a><a style="color: grey;"> > Payment Confirmation </a>  </span>
                                    </div>
                                    </div>
                                    
                                    <div class="cl-info-footer" id="id-title-bar" style="display:flex; margin-top:15px; width:100%">
                                        <div class="" id="id-project-title-text" style="align-self: auto;">
                                            <span class="cl-span-site-title">Project Submission Payment Confirmation </span>
                                        </div>
                                    </div>

                                    <div class="cl-info-footer" id="id-title-bar" style="display:flex; margin-top:15px; width:100%; background:none">
                                        <div class="" id="id-project-title-text" style="align-self: auto;">
                                            <span class="cl-span-site-title">Project Summary</span>
                                            <span style="padding-left:448px;" class="cl-span-site-title">Enter Billing Information</span>
                                        </div>
                                    </div>

                                    <!-- <div class="cl-info-footer" id="id-title-bar" style="display:flex; margin-top:15px; width:100%; float:right; background:none">
                                            <div class="" id="id-project-title-text" style="align-self: auto;">
                                                 
                                        </div>
                                    </div> -->

                                    <div class="col-md-12" style="padding-left:10px;">
                                        <div style="width:500px; float:left; height:490px; padding-left:5px;" id="id-payment-summary-tbl">
                                            <div>
                                            <div style="float:left;"><b> Project Name : </b> </div> 
                                            <div style="background: #f9f9f9; padding-left:175px" id ="UD-payments-projectname"> </div>
                                            <div style="float:left;"><b> Building Area : </b></div> 
                                            <div style="padding-left:175px" id ="UD-payments-buildingarea"> </div>
                                            <div style="float:left;"><b> Site Area : </b></div> 
                                            <div style="background: #f9f9f9; padding-left:175px" id ="UD-payments-sitearea"> </div>
                                            </div>
                                            
                                            <div class="" id="id-project-title-text" style="align-self: auto; font-size:large">
                                                <span class="cl-span-site-title">Project Cost Breakdown</span>
                                            </div>

                                            <!-- On-Site Audit -->
                                            <div id="on-site-div" style="margin-top: 10px; display:none;">
                                                <div style="padding-top:10px;">
                                                    <b> Final Certification (with on-site audit) </b> <span style="float:right; padding-right:100px; font-weight:bold"> Cost </span>
                                                    <hr class="calculator-hr">
                                                    <p></p>
                                                    <div style="padding-left:25px;">
                                                        <div>
                                                            Building: <span id="id-onsite-buidling" style="float:right; padding-right:85px;"> $0 </span>
                                                        </div>
                                                        <div>
                                                            Site: <span id="id-onsite-site" style="float:right; padding-right:85px;"> $0 </span>
                                                        </div>
                                                        
                                                        <div id="onsitecontainer"> Subtotal: <span id="id-onsite-total" style="float:right; padding-right:85px;"> $0 </span> </div>
                                                    </div>
                                                </div>  
                                            </div>
                                            <br>
                                            
                                            <!-- Pre-certification -->
                                            <div id="pre-cert-div" style="display:none;">
                                                <b> Pre-certification</b>
                                                <hr class="calculator-hr">
                                                <p></p>
                                                <div style="padding-left:25px;">
                                                    <div>
                                                        Building: <span id="id-precert-buidling" style="float:right; padding-right:85px;"> $0 </span>
                                                    </div>
                                                    <div>
                                                        Site: <span id="id-precert-site" style="float:right; padding-right:85px;"> $0 </span>
                                                    </div>
                                                    
                                                    <div id="precertcontainer"> Subtotal: <span id="id-precert-total" style="float:right;padding-right:85px;"> $0 </span></div>
                                                </div> 
                                            </div>
                                            <br>
                                            <div style="background: #f9f9f9;">
                                            <span id="id-total-est" style="float:right; padding-right:85px;"> $0 </span>
                                            <b> Total Amount Due </b> 
                                            </div>

                                        </div>
                                        <!-- <div class="col-md-8 thick-border-no-grid"> -->
                                            <!-- <div class="cl-div-section-msg">
                                                <h5>Enter Billing Information</h5>
                                            </div> -->

                                            <form id="create_billing_form" style="padding-left: 600px; width: 1200px;" method="post">
                                                <div>
                                                    <div class="row form-group">
                                                        <div class="col-md-6">
                                                            <label for="payment-firstname">First Name</label>
                                                            <input type="text" class="form-control" id="payment-firstname" placeholder="First Name" pattern="^([a-zA-Z,.\-'\s\(\)]{3,20})$" required>
                                                        </div>
                                                        <div class="col-md-6">
                                                            <label for="payment-lastname">Last Name</label>
                                                            <input type="text" class="form-control" id="payment-lastname" placeholder="Last Name" pattern="^([a-zA-Z,.\-'\s\(\)]{3,20})$" required>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="payment-address">Street Address</label>
                                                            <input type="text" class="form-control" id="payment-address" placeholder="Street Address" required>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-6">
                                                            <label for="payment-city">City</label>
                                                            <input type="text" class="form-control" id="payment-city" placeholder="City" pattern="^[a-zA-z] ?([a-zA-z]|[a-zA-z] )*[a-zA-z]$" required>
                                                        </div>
                                                        <div class="col-md-6">
                                                            <label for="payment-state">State</label>
                                                            <select class="form-control" id="payment-state" name="province" required>
                                                                    <?php
                                                                        include_once("us_states.php");
                                                                    ?>
                                                            </select>
                                                        </div>
                                                    </div>

                                                    <div class="row form-group">
                                                        <div class="col-md-6">
                                                            <label for="payment-zip">Postal/Zip Code</label>
                                                            <input type="text" class="form-control" id="payment-zip" placeholder="Postal/Zip Code" pattern="^\d{5}(?:[-\s]\d{4})?$" required>
                                                        </div>
                                                        <div class="col-md-6">
                                                            <label for="payment-country">Country</label>
                                                            <select class="form-control" id="payment-country" required>
                                                                   <?php
                                                                        include_once("countries.php");
                                                                    ?>
                                                            </select>
                                                        </div>
                                                    </div>

                                                    <div class="row form-group">
                                                        <div class="col-md-6">
                                                            <label for="payment-email">E-mail</label>
                                                            <input type="Email" class="form-control" id="payment-email" placeholder="E-mail" required>
                                                        </div>
                                                        <div class="col-md-6">
                                                            <label for="payment-phone">Phone Number</label>
                                                            <input type="text" class="form-control" id="payment-phone" placeholder="Phone Number" required>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12" style="font-size: 0.9em;">
                                                            <i>(<u>Note:</u> You will be redirected to the University at Buffalo's secure payment gateway to complete the payment after clicking continue)</i>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-md-4 cl-ignore-bs-padding cl-ignore-bs-right-padding" style="float: right;text-align: right;">
                                                    <div class="col-md-12 cl-ignore-bs-padding cl-ignore-bs-right-padding">
                                                        <input type="button" class="btn btn-primary" name="back" id="payment-backbtn" value="Back">
                                                        <input type="button" name="continue" class="btn btn-primary" id="payment-billing-submit" text= "Continue" value="Continue">
                                                    </div>

                                                </div>
                                            </form>
                                        <!-- </div> -->
                                    </div>
                                </section>
                                <?php
                                include_once("Footer.php");
                            ?>
                            </div>
                        </div>
                    </div>
                </section><script src="JS/map.min.545075f8.js"></script><script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/tether/1.1.1/js/tether.min.js"></script><script src="JS/bootstrap.min.61f338f8.js"></script><script src="JS/bootstrap-select.min.69c3d792.js"></script><script src="JS/lib-unveil.min.c14400f8.js"></script><script src="JS/banner.min.481c978f.js"></script><script src="JS/index.min.4e09dd2c.js"></script><script src="JS/payments.min.89791cff.js"></script></div></body></html>