2 if (!isset($path_to_root) || isset($_GET['path_to_root']) || isset($_POST['path_to_root']))
3 die("Restricted access");
4 include_once($path_to_root . "/includes/ui/ui_view.inc");
5 // Display demo user name and password within login form if "$allow_demo_mode" is true
7 if ($allow_demo_mode == True)
9 $demo_text = "Login as user: demouser and password: cooldemo";
13 $demo_text = "Please login here";
17 $def_theme = $path_to_root . '/themes/default';
21 <?php echo get_js_png_fix(); ?>
22 <script type="text/javascript">
23 function defaultCompany()
25 document.forms[0].company_login_name.options[<?php echo $def_coy; ?>].selected = true;
26 document.getElementById('ui_mode').value = 1;
29 <title><?php echo $app_title . " " . $version;?></title>
30 <meta http-equiv="Content-type" content="text/html; charset=iso-8859-1" />
31 <link rel="stylesheet" href="<?php echo $def_theme;?>/login.css" type="text/css" />
34 <body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="defaultCompany()">
35 <table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
37 <td align="center" valign="bottom"><a target="_blank" href="<?php $power_url; ?>"><img src="<?php echo $def_theme;?>/images/logo_frontaccounting.png" alt="FrontAccounting" width="250" height="50" onload="fixPNG(this)" border="0" /></a></td>
41 <td align="center" valign="top">
43 <table border="0" cellpadding="0" cellspacing="0">
44 <tr><td colspan=2 align="center"><font size=4><b><?php echo _("Version") . " " . $version . " Build " . $build_version ?></b></font><br><br></td></tr>
46 <td colspan="2" rowspan="2">
47 <table width="346" border="0" cellpadding="0" cellspacing="0">
48 <form action="<?php echo $_SERVER['PHP_SELF'];?>" name="loginform" method="post">
49 <input type="hidden" id=ui_mode name="ui_mode" value="0">
51 <td colspan="5" bgcolor="#FFFFFF"><img src="<?php echo $def_theme; ?>/images/spacer.png" width="346" height="1" alt="" /></td>
59 <td bgcolor="#367CB5"><img src="<?php echo $def_theme; ?>/images/spacer.png" width="12" height="200" alt="" /></td>
61 <!--<td background="<?php echo $def_theme; ?>/images/outline/bg.png" width="233" height="200" colspan="3" valign="top">-->
62 <td class="login" colspan="3" valign="top">
63 <table border="0" cellpadding="3" cellspacing="0" width="100%">
66 <!--<span class="loginText">Client login<input name="external_login" type="checkbox" value="1" class="loginText"></span>-->
71 <td width="90"></td><td class="loginText" width="283"><span>User name:</span><br />
72 <input type="text" name="user_name_entry_field"/><br />
73 <span>Password:</span><br />
74 <input type="password" name="password">
76 <span>Company:</span><br />
77 <!--<select name="company_login_name" onchange="setCookie()">-->
78 <select name="company_login_name">
80 for ($i = 0; $i < count($db_connections); $i++)
82 echo "<option value=$i>" . $db_connections[$i]["name"] . "</option>";
87 <?php echo $demo_text;?>
92 <td></td><td align="left"><input type="submit" value=" Login -->" name="SubmitUser" /></td>
98 <td colspan="5" bgcolor="#FFFFFF"><img src="<?php echo $def_theme; ?>/images/spacer.png" width="346" height="1" alt="" /></td>
103 <!--<td background="<?php echo $def_theme; ?>/images/outline/r.png" colspan="3" align="right" valign="top"><img src="<?php echo $def_theme; ?>/images/outline/tr.png" width="10" height="10" alt="" /></td>-->
106 <!--<td background="<?php echo $def_theme; ?>/images/outline/r.png"><img src="<?php echo $def_theme; ?>/images/outline/r.png" width="10" height="10" alt=""></td>-->
109 <!--<td background="<?php echo $def_theme; ?>/images/outline/bm.png"><img src="<?php echo $def_theme; ?>/images/outline/bl.png" width="10" height="10" alt=""></td>-->
110 <!--<td background="<?php echo $def_theme; ?>/images/outline/bm.png"><img src="<?php echo $def_theme; ?>/images/outline/bm.png" width="10" height="10" alt=""></td>-->
111 <!--<td><img src="<?php echo $def_theme; ?>/images/outline/br.png" width="10" height="10" alt="" /></td>-->
113 <tr><td> </td></tr><tr>
114 <td align="center" class="footer"><font size=1><a target='_blank' style="text-decoration: none" HREF='<?php echo $power_url; ?>'><font color="#FFFF00" valign="top"> <?php echo $power_by; ?></font></a></font></td>
116 <!--<tr><td> </td></tr><tr>
117 <td align="center" class="footer"><a target="_blank" HREF="http://frontaccounting.com/"><img src="<?php echo $def_theme; ?>/images/logo_frontaccounting.png" height="60" width="60" border="0"/></a></td>
120 if ($allow_demo_mode == true)
124 <!--<td><br><div align="center"><a href="http://frontaccounting.com"><img src="<?php echo $def_theme; ?>/images/logo_frontaccounting.png" border="0" align="middle" /></a></div></td>-->
134 <script language="JavaScript" type="text/javascript">
137 document.forms[0].user_name_entry_field.select();
138 document.forms[0].user_name_entry_field.focus();