2008년 3월 16일 일요일

[강좌] xajax 강좌 #3

아래는 추가적으로 함수 안에서 쓸수 있는 함수들이다.
구찮아서 해석은 하지 않습니다. -_-

addAssign($sTargetId,$sAttribute,$sData)

Assigns the $sAttribute of the element identified by $sTargetId to $sData

$objResponse->addAssign("contentDiv","innerHTML","Some
Text");

$objResponse->addAssign("checkBox1","checked","true");


addAppend($sTargetId,$sAttribute,$sData)

Appends $sData to the $sAttribute of the element identified by $sTargetId

$objResponse->addAppend("contentDiv","innerHTML","Some
Text");


addPrepend($sTargetId,$sAttribute,$sData)

Prepends $sData to the $sAttribute of the element identified by $sTargetId

$objResponse->addPrepend("contentDiv","innerHTML","Some
Text");


addReplace($sTargetId,$sAttribute,$sSearch,$sData)

replaces all instances of $sSearch with $sData in the $sAttribute of the element
identified by $sTargetId

$objResponse->addReplace("contentDiv","innerHTML","text","<strong>text</strong>");


addClear($sTargetId,$sAttribute)

Clears the $sAttribute of the element identified by $sTargetId

$objResponse->addClear("Input1","value");


addCreate($sParentId, $sTagname, $sId, $sType)

Adds a new $sTagName child element to an existing element identified by $sParentId,
and assigns it the id $sId and the optional type $sType.

$objResponse->addCreate("form1","input", "pass", "password");


addRemove($sElementId)

Removes the element identified by $sElementId from your application

$objResponse->addRemove("div1");


addAlert($sMsg)

Display an alert box with $sMsg

$objResponse->addAlert("This is some text");


addScript($sJS)

Execute the JavaScript code $sJS

$objResponse->addAlert("var txt = prompt('get some text');");


댓글 없음: