Class JFile. Jfile joomla


JFile (Документация по Joomla 2.5.4)

Вернуться к записям по теме Joomla.

Joomla.Platform\JFile

libraries/joomla/filesystem/file.php at line 21 JFile

public class JFile

Subpackage: FileSystem Since: 11.1 Method Summary
static string

getExt(string file)

Gets the extension of a file name

static string

stripExt(string file)

Strips the last extension off of a file name

static string

makeSafe(string file)

Makes file name safe to use

static boolean

copy(string src, string dest, string path, boolean use_streams)

Copies a file

static boolean

delete(mixed file)

Delete a file or array of files

static boolean

move(string src, string dest, string path, boolean use_streams)

Moves a file

static mixed

read(string filename, boolean incpath, integer amount, integer chunksize, integer offset)

Read the contents of a file

static boolean

write(string file, string &$buffer, boolean use_streams, mixed buffer)

Write contents to a file

static boolean

upload(string src, string dest, boolean use_streams)

Moves an uploaded file to a destination folder

static boolean

exists(string file)

Wrapper for the standard file_exists function

static string

getName(string file)

Returns the name, without any path.

Method Detail

libraries/joomla/filesystem/file.php at line 32

getExt

public static string getExt(string file)

Gets the extension of a file name

Parameters: file - The file name Returns: The file extension Since: 11.1 libraries/joomla/filesystem/file.php at line 48

stripExt

public static string stripExt(string file)

Strips the last extension off of a file name

Parameters: file - The file name Returns: The file name without the extension Since: 11.1 libraries/joomla/filesystem/file.php at line 62

makeSafe

public static string makeSafe(string file)

Makes file name safe to use

Parameters: file - The name of the file [not full path] Returns: The sanitised string Since: 11.1 libraries/joomla/filesystem/file.php at line 81

copy

public static boolean copy(string src, string dest, string path, boolean use_streams)

Copies a file

Parameters: src - The path to the source file dest - The path to the destination file path - An optional base path to prefix to the file names use_streams - True to use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 163

delete

public static boolean delete(mixed file)

Delete a file or array of files

Parameters: file - The file name or an array of file names Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 234

move

public static boolean move(string src, string dest, string path, boolean use_streams)

Moves a file

Parameters: src - The path to the source file dest - The path to the destination file path - An optional base path to prefix to the file names use_streams - True to use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 313

read

public static mixed read(string filename, boolean incpath, integer amount, integer chunksize, integer offset)

Read the contents of a file

Parameters: filename - The full file path incpath - Use include path amount - Amount of file to read chunksize - Size of chunks to read offset - Offset of the file Returns: Returns file contents or boolean False if failed Since: 11.1 libraries/joomla/filesystem/file.php at line 375

write

public static boolean write(string file, string &$buffer, boolean use_streams, mixed buffer)

Write contents to a file

Parameters: file - The full file path &$buffer - The buffer to write use_streams - Use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 436

upload

public static boolean upload(string src, string dest, boolean use_streams)

Moves an uploaded file to a destination folder

Parameters: src - The name of the php (temporary) uploaded file dest - The path (including filename) to move the uploaded file to use_streams - True to use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 521

exists

public static boolean exists(string file)

Wrapper for the standard file_exists function

Parameters: file - File path Returns: True if path is a file Since: 11.1 libraries/joomla/filesystem/file.php at line 535

getName

public static string getName(string file)

Returns the name, without any path.

Parameters: file - File path Returns: filename Since: 11.1 Вернуться к записям по теме Joomla.

ya.samposebe.ru

JFile *Документация по Joomla 3.0.2

Вернуться к записям по теме Joomla.

Joomla.Platform\JFile

libraries/joomla/filesystem/file.php at line 21 JFile

public class JFile

Subpackage: FileSystem Since: 11.1 Method Summary
static string

getExt(string file)

Gets the extension of a file name

static string

stripExt(string file)

Strips the last extension off of a file name

static string

makeSafe(string file)

Makes file name safe to use

static boolean

copy(string src, string dest, string path, boolean use_streams)

Copies a file

static boolean

delete(mixed file)

Delete a file or array of files

static boolean

move(string src, string dest, string path, boolean use_streams)

Moves a file

static mixed

read(string filename, boolean incpath, integer amount, integer chunksize, integer offset)

Read the contents of a file

static boolean

write(string file, string &$buffer, boolean use_streams, mixed buffer)

Write contents to a file

static boolean

upload(string src, string dest, boolean use_streams)

Moves an uploaded file to a destination folder

static boolean

exists(string file)

Wrapper for the standard file_exists function

static string

getName(string file)

Returns the name, without any path.

Method Detail

libraries/joomla/filesystem/file.php at line 32

getExt

public static string getExt(string file)

Gets the extension of a file name

Parameters: file - The file name Returns: The file extension Since: 11.1 libraries/joomla/filesystem/file.php at line 48

stripExt

public static string stripExt(string file)

Strips the last extension off of a file name

Parameters: file - The file name Returns: The file name without the extension Since: 11.1 libraries/joomla/filesystem/file.php at line 62

makeSafe

public static string makeSafe(string file)

Makes file name safe to use

Parameters: file - The name of the file [not full path] Returns: The sanitised string Since: 11.1 libraries/joomla/filesystem/file.php at line 81

copy

public static boolean copy(string src, string dest, string path, boolean use_streams)

Copies a file

Parameters: src - The path to the source file dest - The path to the destination file path - An optional base path to prefix to the file names use_streams - True to use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 158

delete

public static boolean delete(mixed file)

Delete a file or array of files

Parameters: file - The file name or an array of file names Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 225

move

public static boolean move(string src, string dest, string path, boolean use_streams)

Moves a file

Parameters: src - The path to the source file dest - The path to the destination file path - An optional base path to prefix to the file names use_streams - True to use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 299

read

public static mixed read(string filename, boolean incpath, integer amount, integer chunksize, integer offset)

Read the contents of a file

Parameters: filename - The full file path incpath - Use include path amount - Amount of file to read chunksize - Size of chunks to read offset - Offset of the file Returns: Returns file contents or boolean False if failed Since: 11.1 Deprecated: 13.3 Use the native file_get_contents() instead. libraries/joomla/filesystem/file.php at line 364

write

public static boolean write(string file, string &$buffer, boolean use_streams, mixed buffer)

Write contents to a file

Parameters: file - The full file path &$buffer - The buffer to write use_streams - Use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 424

upload

public static boolean upload(string src, string dest, boolean use_streams)

Moves an uploaded file to a destination folder

Parameters: src - The name of the php (temporary) uploaded file dest - The path (including filename) to move the uploaded file to use_streams - True to use streams Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 507

exists

public static boolean exists(string file)

Wrapper for the standard file_exists function

Parameters: file - File path Returns: True if path is a file Since: 11.1 libraries/joomla/filesystem/file.php at line 522

getName

public static string getName(string file)

Returns the name, without any path.

Parameters: file - File path Returns: filename Since: 11.1 Deprecated: 13.3 Use basename() instead. Вернуться к записям по теме Joomla.

ya.samposebe.ru

JFile (Документация по Joomla 1.7)

Вернуться к записям по теме Joomla.

Joomla.Platform\JFile

libraries/joomla/filesystem/file.php at line 21 JFile

public class JFile

Subpackage: FileSystem Since: 11.1 Method Summary
static string

getExt(string file)

Gets the extension of a file name

static string

stripExt(string file)

Strips the last extension off of a file name

static string

makeSafe(string file)

Makes file name safe to use

static boolean

copy(string src, string dest, string path, bool use_streams)

Copies a file

static boolean

delete(mixed file)

Delete a file or array of files

static boolean

move(string src, string dest, string path, bool use_streams)

Moves a file

static mixed

read(string filename, boolean incpath, integer amount, integer chunksize, integer offset)

Read the contents of a file

static boolean

write(string file, string buffer, bool use_streams)

Write contents to a file

static boolean

upload(string src, string dest, bool use_streams)

Moves an uploaded file to a destination folder

static boolean

exists(string file)

Wrapper for the standard file_exists function

static string

getName(string file)

Returns the name, without any path.

Method Detail

libraries/joomla/filesystem/file.php at line 31

getExt

public static string getExt(string file)

Gets the extension of a file name

Parameters: file - The file name Returns: The file extension Since: 11.1 libraries/joomla/filesystem/file.php at line 46

stripExt

public static string stripExt(string file)

Strips the last extension off of a file name

Parameters: file - The file name Returns: The file name without the extension Since: 11.1 libraries/joomla/filesystem/file.php at line 59

makeSafe

public static string makeSafe(string file)

Makes file name safe to use

Parameters: file - The name of the file [not full path] Returns: The sanitised string Since: 11.1 libraries/joomla/filesystem/file.php at line 76

copy

public static boolean copy(string src, string dest, string path, bool use_streams)

Copies a file

Parameters: src - The path to the source file dest - The path to the destination file path - An optional base path to prefix to the file names Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 146

delete

public static boolean delete(mixed file)

Delete a file or array of files

Parameters: file - The file name or an array of file names Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 204

move

public static boolean move(string src, string dest, string path, bool use_streams)

Moves a file

Parameters: src - The path to the source file dest - The path to the destination file path - An optional base path to prefix to the file names Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 271

read

public static mixed read(string filename, boolean incpath, integer amount, integer chunksize, integer offset)

Read the contents of a file

Parameters: filename - The full file path incpath - Use include path amount - Amount of file to read chunksize - Size of chunks to read offset - Offset of the file Returns: Returns file contents or boolean False if failed Since: 11.1 libraries/joomla/filesystem/file.php at line 323

write

public static boolean write(string file, string buffer, bool use_streams)

Write contents to a file

Parameters: file - The full file path buffer - The buffer to write Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 375

upload

public static boolean upload(string src, string dest, bool use_streams)

Moves an uploaded file to a destination folder

Parameters: src - The name of the php (temporary) uploaded file dest - The path (including filename) to move the uploaded file to Returns: True on success Since: 11.1 libraries/joomla/filesystem/file.php at line 442

exists

public static boolean exists(string file)

Wrapper for the standard file_exists function

Parameters: file - File path Returns: True if path is a file Since: 11.1 libraries/joomla/filesystem/file.php at line 455

getName

public static string getName(string file)

Returns the name, without any path.

Parameters: file - File path Returns: filename Since: 11.1 Вернуться к записям по теме Joomla.

ya.samposebe.ru


Смотрите также

Prostoy-Site | Все права защищены © 2018 | Карта сайта