BEAR_Page
[ class tree: BEAR_Page ] [ index: BEAR_Page ] [ all elements ]

Class: BEAR_Page_Ajax

Source Location: /BEAR/Page/Ajax.php

Class Overview

BEAR_Base
   |
   --BEAR_Page_Ajax

BEAR_Page_Ajax


Author(s):

Version:

  • SVN: Release: @package_version@ $Id: Ajax.php 2486 2011-06-06 07:44:05Z koriyama@bear-project.net $

Copyright:

  • 2008-2011 Akihito Koriyama All rights reserved.

Methods


Inherited Variables

Inherited Methods


Class Details

[line 33]
BEAR_Page_Ajax

BEAR_Page_Ajax




Tags:

author:  Akihito Koriyama <koriyama@bear-project.net>
version:  SVN: Release: @package_version@ $Id: Ajax.php 2486 2011-06-06 07:44:05Z koriyama@bear-project.net $
copyright:  2008-2011 Akihito Koriyama All rights reserved.
link:  http://www.bear-project.net/
license:  BSD


[ Top ]


Class Methods


method addAjax [line 161]

void addAjax( string $ajaxCommand, $data, [ $options = array()])

AJAXコマンドを追加

AJAXコマンドを追加

  1.   // リソースをアサイン
  2.   $this->addAjax('resource'array('div_person1' => 'person')array('effect' => 'slideup'));
  3.   // 生のデータをアサイン
  4.   $this->addAjax('html'array('msg' => '使用できます!')array('effect' => 'splash'));
  5.   // フォームの値を変更
  6.   $this->addAjax('form'array('post' => '123''post2' => '4567'));
  7.   // JSをコール
  8.   $this->addAjax('js'array('callback1' => $_SERVER'callback2' => $_COOKIE));
  9.  // 出力
  10.   $this->output('ajax');




Tags:

access:  public


Parameters:

string   $ajaxCommand   AJAXコマンド 'html' | 'resource' |'form' | 'js'
array   $data   AJAXコマンド引数
array   $options   AJAXコマンドオプション

[ Top ]

method checkSecurity [line 71]

void checkSecurity( )

セキュリティチェック

セキュリティチェック AJAXリクエストが不正なものでないかチェックします。




Tags:

throws:  BEAR_Page_Exception
access:  public


[ Top ]

method getAjaxRequest [line 119]

array getAjaxRequest( )

bear.

bear.jsからのAJAXリクエストのクライアント値を受け取る

 クライアントのフォームとBear.Valueの値をonInit($args)の$argsにします。

 フォーマット:
 array('form' =>array('フォーム名1' => 'フォーム1データ', 'フォーム名2' => 'フォーム1データ',
   'value' => 'Bear.Value');
  1.  <a href="/" rel="ajax[loading1]">ajax request</a>




Tags:

access:  public


[ Top ]

method isAjaxRequest [line 97]

boolean isAjaxRequest( )

AJAXリクエストかどうかを返す

AJAXリクエストかどうかを返す prototype.js jQuery他で動作します




Tags:

access:  public


[ Top ]

method onInject [line 53]

void onInject( )

Inject

Inject




Tags:

access:  public


Overrides BEAR_Base::onInject() (Inject)

[ Top ]


Documentation generated on Sat, 30 Jul 2011 00:09:58 +0900 by phpDocumentor 1.4.3