浏览代码

fixed login problems

Luke Ehresman 25 年之前
父节点
当前提交
f30a12c0b8
共有 3 个文件被更改,包括 10 次插入7 次删除
  1. 6 6
      functions/imap_general.php
  2. 0 1
      functions/prefs.php
  3. 4 0
      src/webmail.php

+ 6 - 6
functions/imap_general.php

@@ -89,12 +89,13 @@
             } else if (substr($read, 0, 7) == "a001 NO") {
                ?>
                   <html>
-                     <body bgcolor=<? echo $color[4] ?>>
+                     <body bgcolor=ffffff>
                         <br>
-                        <table width=70% noborder bgcolor=<? echo $color[4] ?> align=center>
+                        <center>
+                        <table width=70% noborder bgcolor=ffffff align=center>
                            <tr>
-                              <td bgcolor=<? echo $color[0] ?>>
-                                 <font color=<? echo $color[2] ?>>
+                              <td bgcolor=dcdcdc>
+                                 <font color=cc0000>
                                  <center>
                                  <? echo _("ERROR") ?>
                                  </center>
@@ -103,15 +104,14 @@
                            </tr>
                            <tr>
                               <td>
-                                 <font color=<? echo $color[2] ?>>
                                  <center>
                                  <? echo _("Unknown user or password incorrect.") ?><br>
                                  <a href="login.php"><? echo _("Click here to try again") ?></a>
                                  </center>
-                                 </font>
                               </td>
                            </tr>
                         </table>
+                        </center>
                      </body>
                   </html>
                <?

+ 0 - 1
functions/prefs.php

@@ -81,7 +81,6 @@
             exit;
          }
       }
-      return;
    }
 
 

+ 4 - 0
src/webmail.php

@@ -23,7 +23,11 @@
 <?
    include ("../config/config.php");
    include ("../functions/prefs.php");
+   include ("../functions/imap.php");
 
+   // verify that username and password are correct
+   $imapConnection = sqimap_login($username, $key, $imapServerAddress, 0);
+   
    include ("../src/load_prefs.php");
    
    echo "<TITLE>";