<?php
###################################################################
##                           WARNING!                            ##
##                                                               ##
##         THIS SCRIPT IS COPYRIGHTED TO EASYBUILDR.COM          ##
##      DUPLICATING, SELLING OR TRANSFERRING OF THIS SCRIPT      ##
##    IS A VIOLATION OF THE COPYRIGHT AND PURCHASE AGREEMENT     ##
##          PLEASE READ THE TERMS AND CONDITIONS HERE:           ##
##            https://easybuildr.com/members/terms/              ##
## ANY VIOLATION OF THESE TERMS WILL BE DEALT WITH LEGAL ACTION! ##
###################################################################
error_reporting(E_ERROR);
ini_set('display_errors',1);
session_start();
$_SESSION['sec']=0;
$htaccess_path = dirname( __DIR__ ) . '/.htaccess';
if ( !file_exists( $htaccess_path ) ){
    file_put_contents(
        $htaccess_path,
        'RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond $0#%{REQUEST_URI} ([^#]*)#(.*)\1$
RewriteRule ^(.*)$ %2showpage.php?view=$1 [QSA,L]'
    );
}
?>
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8'>
<title>Easy Page Buildr Admin Area</title>
<link href="css/style.css" rel="stylesheet" type="text/css">
</head>

<body>
<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0" class="table_border">
  <tr>
    <td colspan="2" align="left" valign="top"><div align="center" class="header_bg"><img src="images/logo.png" width="597" height="77" /></div></td>
  </tr>
  <tr>
    <td width="250" align="center" valign="top" style="padding-left:10px; padding-right:10px; padding-top:20px; padding-bottom:20px">
<!--Side Nav -->
<table width="250" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td align="center" valign="middle"></td>
  </tr>
  <tr>
    <td align="center" valign="middle"><div class="red-div"><strong>Log Into Your Admin Panel With Your Username & Password!</strong></div></td>
  </tr>
  <tr>
    <td align="center" valign="middle"></td>
  </tr>
</table>
<!--Side Nav -->    </td>
    <td width="706" align="left" valign="top" style="padding-left:10px; padding-right:10px; padding-top:20px; padding-bottom:20px"><div class="members_title"><strong>Admin Login</strong></div>
      <!--Main -->
      <table width="705" border="0" align="center" cellpadding="0" cellspacing="0">
    <form name="frm" action="admin_main_settings.php" method="post">
            <input type="hidden" name="do_type" value="admin_settings_read">
            <tr>
              <td height="50" align="center" valign="middle" class="title1">&nbsp;</td>
            </tr>
            <?php
		if($_REQUEST['flag']==1)
		  {
?>
            <tr>
              <td height="50" align="center" valign="middle" class="error">Wrong, username/password. Please try again <img src="images/x-red.png" width="20" height="20" align="absmiddle" /></td>
            </tr>
            <?php
		}
?>
            <?php
		if($_REQUEST['flag']==2)
		  {
?>
            <tr>
              <td height="50" align="center" valign="middle" class="error">You need to login in to access that page <img src="images/x-red.png" width="20" height="20" align="absmiddle" /></td>
            </tr>
            <?php
		}
?>
            <tr>
              <td height="50" align="center" valign="middle">Username: 
              <input name="username" type="text" style="width:300px"></td>
            </tr>
            <tr>
              <td height="50" align="center" valign="middle">Password: 
              <input name="pass" type="password" style="width:300px"></td>
            </tr>
            <tr>
              <td height="20" align="center" valign="middle">&nbsp;</td>
            </tr>
            <tr>
              <td height="50" align="center" valign="middle"><p>
                  <input type="submit" name="Submit" value="Login" id="submit">
              </p></td>
            </tr>
            <tr>
              <td height="60" align="center" valign="middle">
              <br>
              <br>
                  <a href="forgot.php">Forgot Your Username/Password? Click Here.</a>
                  <br>
                  <br>              </td>
            </tr>
          </form>
      </table>
<!--Main --></td>
  </tr>
</table>
<div align="center"><span class="footer_policy">No part of this website may be reproduced or transmitted in any form or by any means without written permission from EasyBuildr.com<br />
        <strong>Copyright
<script type="text/javascript" language="JavaScript">function getCorrectedYear(year) {
year = year - 0;
if (year < 70) return (2000 + year);
if (year < 1900) return (1900 + year);
return year;
}
var lmod = new Date();
var yearstr = getCorrectedYear(lmod.getYear());
document.write(yearstr);
// -->
</script>, EasyBuildr.com. All Rights Reserved.</strong></span></div>
</body>
</html>
