phpBMS

Changeset 485 for trunk/phpbms/index.php

Show
Ignore:
Timestamp:
04/07/09 11:44:18 (3 years ago)
Author:
nate
Message:
  • Merged Nathan branch back into trunk.
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/phpbms/index.php

    r308 r485  
    1 <?php  
     1<?php 
    22/* 
    33 $Rev$ | $LastChangedBy$ 
     
    3939        require_once("include/session.php"); 
    4040        require_once("include/login_include.php"); 
    41          
    42         $pageTitle = APPLICATION_NAME." Log in"; 
    43          
     41 
     42 
     43        if(isset($_POST["name"]) && isset($_POST["password"])){ 
     44 
     45                $login = new login($db); 
     46                $failed = $login->verify($_POST["name"], $_POST["password"]); 
     47 
     48        } else { 
     49 
     50                $failed = ""; 
     51                $_POST["name"] = ""; 
     52 
     53        }//endif 
     54 
     55        $pageTitle = formatVariable(APPLICATION_NAME)." Log in"; 
     56 
    4457        $phpbms->cssIncludes[] = "pages/login.css"; 
    4558        $phpbms->jsIncludes[] = "common/javascript/login.js"; 
    46          
     59 
    4760        $phpbms->showMenu = false; 
    48         $phpbms->showFooter = false;     
    49          
     61        $phpbms->showFooter = false; 
     62 
    5063        include("header.php"); 
    5164?> 
    52          
     65 
    5366        <div id="loginbox" class="bodyline" > 
     67 
    5468                <h1><span><?php echo APPLICATION_NAME;?></span></h1> 
    5569                <?php if ($failed) {?><div class="standout" id="failed"><?php echo $failed?></div><?php } ?> 
     70 
    5671                <noscript> 
    5772                        <p class="standout" align="center">JavaScript is disabled.</p> 
    5873                        <p> Please check browser requirements.</p> 
    5974                </noscript> 
    60                  
     75 
    6176                <form name="form1" method="post" action="<?php echo $_SERVER["PHP_SELF"]?>"> 
    62                         <fieldset> 
    63                                 <legend>Log In</legend> 
    64                                 <p> 
    65                                         <label for="username">name</label><br /> 
    66                                         <input name="name" type="text" id="username" size="25" maxlength="64" value="<?php echo htmlQuotes($_POST["name"])?>" disabled="disabled"/> 
     77 
     78                        <p> 
     79                                <label for="username">name</label><br /> 
     80                                <input name="name" type="text" id="username" size="25" maxlength="64" value="<?php echo htmlQuotes($_POST["name"])?>" disabled="disabled"/> 
     81                        </p> 
     82 
     83                        <p> 
     84                                <label for="password">password</label><br /> 
     85                                <input name="password" type="password" id="password" size="25" maxlength="24" disabled="disabled"/> 
     86                        </p> 
     87 
     88 
     89                        <p id="moreinfoButtonP"><button id="moreinfoButton" type="button" class="graphicButtons buttonInfo"><span>more info</span></button></p> 
     90                        <p id="buttonP"><button class="Buttons" type="submit" id="loginButton" disabled="disabled">Log In</button></p> 
     91 
     92                </form> 
     93 
     94 
     95                <div id="moreinfo" > 
     96 
     97                        <div class="box"> 
     98 
     99                                <h2><a href="http://www.phpbms.org" title="phpBMS"><span class="alt">phpBMS</span></a></h2> 
     100 
     101                                <h3>Business Management Web Application</h3> 
     102 
     103                                <p class="tiny"> 
     104                                        <a href="requirements.php">browser requirements</a> | 
     105                                        <a href="info.php">about phpBMS</a> 
    67106                                </p> 
    68                                  
    69                                 <p> 
    70                                         <label for="password">password</label><br /> 
    71                                         <input name="password" type="password" id="password" size="25" maxlength="24" disabled="disabled"/> 
    72                                 </p> 
    73                                  
    74                         </fieldset> 
    75                         <p id="buttonP"><button class="Buttons" type="submit" id="loginButton" disabled="disabled">Log In</button></p> 
    76                 </form>          
    77                 <p id="moreinfoButtonP"><button id="moreinfoButton" type="button" class="graphicButtons buttonInfo"><span>more info</span></button></p> 
    78                 <div id="moreinfo" > 
    79                         <div class="box"> 
    80                         <h2><a href="http://www.phpbms.org" title="phpBMS"><span class="alt">phpBMS</span></a></h2> 
    81                         <h3>Business Management Web Application</h3> 
    82                         <p class="tiny"> 
    83                                 <a href="requirements.php">browser requirements</a> | 
    84                                 <a href="info.php">program info</a> 
    85                         </p> 
     107 
    86108                        </div> 
    87109                </div> 
    88110        </div> 
    89111 
    90                  
     112 
    91113        <?php if(DEMO_ENABLED=="true"){?> 
     114 
    92115        <div id="demobox" class="bodyline"> 
     116 
    93117                <h2>Demonstration Mode</h2> 
     118 
    94119                <p> 
    95                         Use the following user credentials to log into phpBMS. Each user  
     120                        Use the following user credentials to log into phpBMS. Each user 
    96121                        highlights a different security access level. 
    97122                </p> 
     123 
    98124                <dl> 
    99125                        <dt>Shipping Personnel</dt> 
     
    101127                                username: shipping<br /> 
    102128                                password: shipping 
    103 </dd> 
     129                        </dd> 
     130 
    104131                        <dt>Sales Personnel</dt> 
    105                         <dd>username: sales<br /> 
    106                         password: sales</dd> 
     132                        <dd> 
     133                                username: sales<br /> 
     134                                password: sales 
     135                        </dd> 
     136 
    107137                        <dt>Sales Manager</dt> 
    108                         <dd>username: salesmanager<br /> 
     138                        <dd> 
     139                                username: salesmanager<br /> 
    109140                                password: salesmanager 
    110                      </dd> 
     141                        </dd> 
    111142                </dl> 
    112143        </div> 
     144 
    113145        <?php } include("footer.php")?> 
phpBMS vulnerability assesment provided by Orvant Inc. Copyright © 2010 Kreotek, LLC. All Rights reserved.