Prepend SM_PATH to $icon_theme_path since it is no longer returned by the template...
[squirrelmail.git] / src / addrbook_popup.php
index a9bee6e95a86d2846f374d74ee2fd35764ed855c..7a9745880a63e6de17a9db70c4402cb099c2e44b 100644 (file)
@@ -1,43 +1,25 @@
 <?php
-   /**
-    **  addrbook_popup.php
-    **
-    **  Frameset for the JavaScript version of the address book.
-    **
-    **/
 
-   session_start();
+/**
+ * addrbook_popup.php
+ *
+ * Frameset for the JavaScript version of the address book.
+ *
+ * @copyright &copy; 1999-2006 The SquirrelMail Project Team
+ * @license http://opensource.org/licenses/gpl-license.php GNU Public License
+ * @version $Id$
+ * @package squirrelmail
+ * @subpackage addressbook
+ */
 
-   if(!isset($logged_in)) {
-      echo _("You must login first.");
-      exit;
-   }
-   if(!isset($username) || !isset($key)) {
-      echo _("You need a valid user and password to access this page!");
-      exit;
-   }
+/**
+ * Include the SquirrelMail initialization file.
+ */
+include('../include/init.php');
 
-   if (!isset($config_php))
-      include("../config/config.php");
-   if (!isset($page_header_php))
-      include("../functions/page_header.php");
-   if (!isset($addressbook_php))
-      include("../functions/addressbook.php");
-?>
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN">
+displayHtmlHeader($org_title .': '. _("AddressBook"), '', false, true);
 
-<HTML>
-<HEAD>
-<TITLE><?php 
-   printf("%s: %s", $org_title, _("Address Book")); 
-?></TITLE>
-</HEAD>
+$oTemplate->display('addressbook_popup.tpl');
 
-<FRAMESET ROWS="60,*" BORDER=0>
- <FRAME NAME="abookmain" MARGINWIDTH=0 SCROLLING=NO
-        SRC="addrbook_search.php?show=form" BORDER=0>
- <FRAME NAME="abookres" MARGINWIDTH=0 SRC="addrbook_search.php?show=blank"
-        BORDER=0>
-</FRAMESET>
-
-</HTML>
+$oTemplate->display('footer.tpl');
+?>
\ No newline at end of file