PHP Class PMA\libraries\Scripts

Afficher le fichier Open project: phpmyadmin/phpmyadmin Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( ) Generates new Scripts objects
addCode ( string $code ) : void Adds a new code snippet to the code to be executed
addFile ( string $filename, boolean $before_statics = false ) : void Adds a new file to the list of scripts
addFiles ( array $filelist ) : void Add new files to the list of scripts
getDisplay ( ) : string Renders all the JavaScript file inclusions, code and events
getFiles ( ) : array Returns a list with filenames and a flag to indicate whether to register onload events for this file

Private Methods

Méthode Description
_eventBlacklist ( string $filename ) : integer Determines whether to fire up an onload event for a file
_includeFiles ( array $files ) : string Returns HTML code to include javascript file.

Method Details

__construct() public méthode

Generates new Scripts objects
public __construct ( )

addCode() public méthode

Adds a new code snippet to the code to be executed
public addCode ( string $code ) : void
$code string The JS code to be added
Résultat void

addFile() public méthode

Adds a new file to the list of scripts
public addFile ( string $filename, boolean $before_statics = false ) : void
$filename string The name of the file to include
$before_statics boolean Whether this dynamic script should be included before the static ones
Résultat void

addFiles() public méthode

Add new files to the list of scripts
public addFiles ( array $filelist ) : void
$filelist array The array of file names
Résultat void

getDisplay() public méthode

Renders all the JavaScript file inclusions, code and events
public getDisplay ( ) : string
Résultat string

getFiles() public méthode

Returns a list with filenames and a flag to indicate whether to register onload events for this file
public getFiles ( ) : array
Résultat array