X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=access%2Flogin.php;h=3bbf0060ec37fcab5ebe32d4a7ee4ad04be2267a;hb=76ca9fef9bb510236a6a7740fa0f60eb7db384c9;hp=759a732755cad0458024568c5f5d86c1315da0cf;hpb=d03e05776f61d2bff8ee3c1e31e78f98716bf099;p=fa-stable.git diff --git a/access/login.php b/access/login.php index 759a7327..3bbf0060 100644 --- a/access/login.php +++ b/access/login.php @@ -11,7 +11,16 @@ ***********************************************************************/ if (!isset($path_to_root) || isset($_GET['path_to_root']) || isset($_POST['path_to_root'])) die(_("Restricted access")); - include_once($path_to_root . "/includes/ui/ui_view.inc"); + include_once($path_to_root . "/includes/ui.inc"); + include_once($path_to_root . "/includes/page/header.inc"); + + $js = ""; + add_js_file('login.js'); // Display demo user name and password within login form if "$allow_demo_mode" is true if ($allow_demo_mode == true) { @@ -23,121 +32,74 @@ } if (!isset($def_coy)) $def_coy = 0; - $def_theme = $path_to_root . '/themes/default'; + $def_theme = "default"; -$login_timeout = $_SESSION["wa_current_user"]->last_act; + $login_timeout = $_SESSION["wa_current_user"]->last_act; - echo " - "; -if (!$login_timeout) { // page header - echo ''; ?> - - <?php echo $app_title . " " . $version;?> - - - + $title = $login_timeout ? _('Authorization timeout') : $app_title." ".$version." - "._("Login"); + $encoding = isset($_SESSION['language']->encoding) ? $_SESSION['language']->encoding : "iso-8859-1"; + $rtl = isset($_SESSION['language']->dir) ? $_SESSION['language']->dir : "ltr"; + $onload = !$login_timeout ? "onload='defaultCompany()'" : ""; - - - <?php echo _('Authorization timeout'); ?> - - - - - - - + echo "\n"; + echo "\n"; + echo "$title\n"; + echo "\n"; + echo " \n"; + send_scripts(); + if (!$login_timeout) + { + echo $js; + } + echo "\n"; - - - - - - - - - - - - - - - - - - - - - - - -
- FrontAccounting - - - -
+ echo "\n"; - - - - - \n"; + end_row(); - - - - - - "; + if (isset($_SESSION['wa_current_user']->company)) + $coy = $_SESSION['wa_current_user']->company; + else + $coy = $def_coy; + echo "


-
- - - - - - - + echo "
$title
\n"; + + div_start('_page_body'); + br();br(); + start_form(false, false, $_SESSION['timeout']['uri'], "loginform"); + start_table(false, "class='login'"); + start_row(); + echo "
"; + if (!$login_timeout) { // FA logo + echo "FrontAccounting"; + } else { + echo ""._('Authorization timeout').""; + } + echo "
"._("Company")."\n"; + start_row(); + label_cell($demo_text, "colspan=2 align='center'"); + end_row(); + }; + end_table(1); + echo "
\n"; foreach($_SESSION['timeout']['post'] as $p => $val) { // add all request variables to be resend together with login data @@ -145,53 +107,34 @@ if (!$login_timeout) { // FA version info 'password', 'SubmitUser', 'company_login_name'))) echo ""; } -?> -
- -
 
+ end_form(1); + $Ajax->addScript(true, "document.forms[0].password.focus();"); - - - - - - + "; + div_end(); + echo "\n"; + echo ""; + if (isset($_SESSION['wa_current_user'])) + $date = Today() . " | " . Now(); + else + $date = date("m/d/Y") . " | " . date("h.i am"); + echo "\n"; + echo "
$date
\n"; + echo "\n"; + echo "\n"; + echo "\n"; + echo "\n"; + echo "\n"; + echo "\n"; + echo "\n"; + echo "

\n"; + echo "\n"; + +?> \ No newline at end of file