PHP 클래스 xajax

It also handles processing and executing the command messages in the XML responses sent back to your page from your PHP functions.
파일 보기 프로젝트 열기: xajax/xajax 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( $sRequestURI = null, $sLanguage = null ) * Constructor: xajax
__sleep ( ) * Function: __sleep
__wakeup ( ) * Function: __wakeup
_compile ( $sFolder = null, $bWriteFile = true )
autoCompressJavascript ( $sJsFullFilename = NULL, $bAlways = false ) * Function: autoCompressJavascript
canProcessRequest ( ) * Function: canProcessRequest
challenge ( $algo = null, $value = null ) * Function: challenge
configure ( $sName, $mValue ) * Function: configure
configureMany ( $aOptions ) * Function: configureMany
getConfiguration ( $sName ) * Function: getConfiguration
getGlobalResponse ( ) * Function: getGlobalResponse
getJavascript ( ) * Function: getJavascript
getVersion ( ) * Function: getVersion
printJavascript ( ) * Function: printJavascript Prints the xajax Javascript header and wrapper code into your page.
processRequest ( ) * Function: processRequest
register ( $sType, $mArg ) * Function: register

비공개 메소드들

메소드 설명
_compressSelf ( $sFolder = null )
_detectURI ( ) * Function: _detectURI
loadChallenges ( $sessionKey )
makeChallenge ( $algo, $value )
saveChallenges ( $sessionKey, $challenges )
verifySession ( ) * Function: VerifySession

메소드 상세

__construct() 공개 메소드

Constructs a xajax instance and initializes the plugin system. Parameters: sRequestURI - (optional): The sRequestURI> to be used for calls back to the server. If empty, xajax fills in the current URI that initiated this request.
public __construct ( $sRequestURI = null, $sLanguage = null )

__sleep() 공개 메소드

* Function: __sleep
public __sleep ( )

__wakeup() 공개 메소드

* Function: __wakeup
public __wakeup ( )

_compile() 공개 메소드

public _compile ( $sFolder = null, $bWriteFile = true )

autoCompressJavascript() 공개 메소드

Creates a new xajax_core, xajax_debug, etc... file out of the _uncompressed file with a similar name. This strips out the comments and extraneous whitespace so the file is as small as possible without modifying the function of the code. Parameters: sJsFullFilename - (string): The relative path and name of the file to be compressed. bAlways - (boolean): Compress the file, even if it already exists.
public autoCompressJavascript ( $sJsFullFilename = NULL, $bAlways = false )

canProcessRequest() 공개 메소드

Determines if a call is a xajax request or a page load request. Return: boolean - True if this is a xajax request, false otherwise.
public canProcessRequest ( )

challenge() 공개 메소드

Call this from the top of a xajax enabled request handler to introduce a challenge and response cycle into the request response process. NOTE: Sessions must be enabled to use this feature.
public challenge ( $algo = null, $value = null )

configure() 공개 메소드

Call this function to set options that will effect the processing of xajax requests. Configuration settings can be specific to the xajax core, request processor plugins and response plugins. Parameters: Options include: javascript URI - (string): The path to the folder that contains the xajax javascript files. errorHandler - (boolean): true to enable the xajax error handler, see bErrorHandler> exitAllowed - (boolean): true to allow xajax to exit after processing a request. See bExitAllowed> for more information.
public configure ( $sName, $mValue )

configureMany() 공개 메소드

Set an array of configuration options. Parameters: $aOptions - (array): Associative array of configuration settings
public configureMany ( $aOptions )

getConfiguration() 공개 메소드

Get the current value of a configuration setting that was previously set via configure> or configureMany> Parameters: $sName - (string): The name of the configuration setting Returns: $mValue : (mixed): The value of the setting if set, null otherwise.
public getConfiguration ( $sName )

getGlobalResponse() 공개 정적인 메소드

Returns the object preconfigured with the encoding and entity settings from this instance of . This is used for singleton-pattern response development. Returns: : A object which can be used to return response commands. See also the class.
public static getGlobalResponse ( )

getJavascript() 공개 메소드

See printJavascript> for more information.
public getJavascript ( )

getVersion() 공개 정적인 메소드

Returns: string : The current xajax version.
public static getVersion ( )

printJavascript() 공개 메소드

This should be used to print the javascript code between the HEAD and /HEAD tags at the top of the page. The javascript code output by this function is dependent on the plugins that are included and the functions that are registered.
public printJavascript ( )

processRequest() 공개 메소드

If this is a xajax request (see canProcessRequest>), call the requested PHP function, build the response and send it back to the browser. This is the main server side engine for xajax. It handles all the incoming requests, including the firing of events and handling of the response. If your RequestURI is the same as your web page, then this function should be called before ANY headers or HTML is output from your script. This function may exit, if a request is processed. See bAllowExit>
public processRequest ( )

register() 공개 메소드

Call this function to register request handlers, including functions, callable objects and events. New plugins can be added that support additional registration methods and request processors. Parameters: $sType - (string): Type of request handler being registered; standard options include: XAJAX_FUNCTION: a function declared at global scope. XAJAX_CALLABLE_OBJECT: an object who's methods are to be registered. XAJAX_EVENT: an event which will cause zero or more event handlers to be called. XAJAX_EVENT_HANDLER: register an event handler function. $sFunction || $objObject || $sEvent - (mixed): when registering a function, this is the name of the function when registering a callable object, this is the object being registered when registering an event or event handler, this is the name of the event $sIncludeFile || $aCallOptions || $sEventHandler when registering a function, this is the (optional) include file. when registering a callable object, this is an (optional) array of call options for the functions being registered. when registering an event handler, this is the name of the function.
public register ( $sType, $mArg )