OSDN Git Service

初回コミット(v2.6.17.1)
[magic3/magic3.git] / widgets / reg_user / include / container / reg_userBaseWidgetContainer.php
1 <?php
2 /**
3  * index.php用コンテナクラス
4  *
5  * PHP versions 5
6  *
7  * LICENSE: This source file is licensed under the terms of the GNU General Public License.
8  *
9  * @package    Magic3 Framework
10  * @author     平田直毅(Naoki Hirata) <naoki@aplo.co.jp>
11  * @copyright  Copyright 2006-2012 Magic3 Project.
12  * @license    http://www.gnu.org/copyleft/gpl.html  GPL License
13  * @version    SVN: $Id: reg_userBaseWidgetContainer.php 5221 2012-09-18 13:00:52Z fishbone $
14  * @link       http://www.magic3.org
15  */
16 require_once($gEnvManager->getContainerPath() . '/baseWidgetContainer.php');
17
18 class reg_userBaseWidgetContainer extends BaseWidgetContainer
19 {
20         protected $_userId;                     // 現在のユーザ
21         const CSS_FILE = '/style.css';          // CSSファイルのパス
22         const EMAIL_LOGIN_URL           = '&task=emaillogin&account=%s&pwd=%s';         // Eメールからのログイン用URL
23         // 画面
24         const TASK_PROFILE = 'profile';                 // プロフィール画面
25         
26         /**
27          * コンストラクタ
28          */
29         function __construct()
30         {
31                 // 親クラスを呼び出す
32                 parent::__construct();
33                 
34                 $this->_userId = $this->gEnv->getCurrentUserId();
35         }
36         /**
37          * CSSファイルをHTMLヘッダ部に設定
38          *
39          * CSSファイルをHTMLのheadタグ内に追加出力する。
40          * _assign()よりも後に実行される。
41          *
42          * @param RequestManager $request               HTTPリクエスト処理クラス
43          * @param object         $param                 任意使用パラメータ。
44          * @return string                                               CSS文字列。出力しない場合は空文字列を設定。
45          */
46         function _addCssFileToHead($request, &$param)
47         {
48                 return $this->getUrl($this->gEnv->getCurrentWidgetCssUrl() . self::CSS_FILE);
49         }
50         /**
51          * Eメール送信元を取得
52          *
53          * @return string               送信元アドレス
54          */
55         function getFromAddress()
56         {
57                 $address = $this->gEnv->getSiteEmail();// サイトのメールアドレス
58                 return $address;
59         }
60 }
61 ?>