cakephp-1.3 > AjaxHelper :: observeField()
AjaxHelper
A
AclBase
AclBehavior
AclComponent
AclNode
AclShell
Aco
AcoAction
AjaxHelper
ApcEngine
ApiShell
App
AppController
AppController
AppHelper
AppHelper
AppModel
AppModel
Aro
AuthComponent
B
BakeShell
BakeTask
BehaviorCollection
C
Cache
CacheEngine
CacheHelper
CakeErrorController
CakeLog
CakeRoute
CakeSchema
CakeSession
CakeSocket
ClassRegistry
Component
Configure
ConnectionManager
ConsoleShell
ContainableBehavior
Controller
ControllerTask
CookieComponent
D
DataSource
DbAcl
DbAclSchema
DbConfigTask
DboMssql
DboMysql
DboMysqlBase
DboMysqli
DboOracle
DboPostgres
DboSource
DboSqlite
Debugger
Dispatcher
E
EmailComponent
ErrorHandler
ErrorHandler
ExtractTask
F
File
FileEngine
FileLog
FixtureTask
Folder
FormHelper
H
Helper
HtmlHelper
HttpSocket
I
I18n
I18nModel
i18nSchema
I18nShell
Inflector
IniAcl
J
JavascriptHelper
JqueryEngineHelper
JsBaseEngineHelper
JsHelper
L
L10n
M
MagicDb
MagicFileResource
MediaView
MemcacheEngine
Model
ModelBehavior
ModelTask
MootoolsEngineHelper
Multibyte
N
NumberHelper
O
Object
Overloadable
Overloadable
Overloadable2
Overloadable2
P
PagesController
PagesController
PaginatorHelper
Permission
PluginShortRoute
PluginTask
ProjectTask
PrototypeEngineHelper
R
RequestHandlerComponent
Router
RssHelper
S
Sanitize
Scaffold
ScaffoldView
SchemaShell
Security
SecurityComponent
SessionComponent
SessionHelper
SessionsSchema
Set
Shell
ShellDispatcher
String
T
TemplateTask
TestSuiteShell
TestTask
TextHelper
ThemeView
TimeHelper
TranslateBehavior
TreeBehavior
V
Validation
View
ViewTask
X
XcacheEngine
Xml
XmlElement
XmlHelper
XmlManager
XmlNode
XmlTextNode
observeField
line:430 at
/cake/libs/view/helpers/ajax.php
Observe field and call ajax on change.
Method
(string)
observeField
($field, $options = array())
Parameters
Parameter | Type | Comment | Default |
---|---|---|---|
$field | string | required DOM ID of field to observe | |
$options | array | optional ajax options | array() |
Return
stringComment
Observe field and call ajax on change.
Observes the field with the DOM ID specified by <i>field</i> and makes
an Ajax when its contents have changed.
Required +options+ are:
- <i>frequency</i>:: The frequency (in seconds) at which changes to
this field will be detected.
- <i>url</i>:: @see url() -style options for the action to call
when the field has changed.
Additional options are:
- <i>update</i>:: Specifies the DOM ID of the element whose
innerHTML should be updated with the
XMLHttpRequest response text.
- <i>with</i>:: A Javascript expression specifying the
parameters for the XMLHttpRequest. This defaults
to Form.Element.serialize('$field'), which can be
accessed from params['form']['field_id'].
Additionally, you may specify any of the options documented in
@see linkToRemote().
@param string $field DOM ID of field to observe
@param array $options ajax options
@return string ajax script
@link http://book.cakephp.org/view/1368/observeField
Observes the field with the DOM ID specified by <i>field</i> and makes
an Ajax when its contents have changed.
Required +options+ are:
- <i>frequency</i>:: The frequency (in seconds) at which changes to
this field will be detected.
- <i>url</i>:: @see url() -style options for the action to call
when the field has changed.
Additional options are:
- <i>update</i>:: Specifies the DOM ID of the element whose
innerHTML should be updated with the
XMLHttpRequest response text.
- <i>with</i>:: A Javascript expression specifying the
parameters for the XMLHttpRequest. This defaults
to Form.Element.serialize('$field'), which can be
accessed from params['form']['field_id'].
Additionally, you may specify any of the options documented in
@see linkToRemote().
@param string $field DOM ID of field to observe
@param array $options ajax options
@return string ajax script
@link http://book.cakephp.org/view/1368/observeField