Garry's Mod Wiki

Garry's Mod Wiki

  string string.GetFileFromFilename( string path )

Description

Returns file name and extension.

Arguments

1 string path
The string eg. file-path to get the file-name from.

Returns

1 string
File name or unmodified string.

Example

Returns the file name.

print( string.GetFileFromFilename( "garrysmod/lua/modules/string.lua" ) )
Output: string.lua

This site is a community mirror of the official Garry's Mod wiki.. This site is not maintained by Facepunch Studios.

Page content is automatically updated four times a day. Edits and history are not available.

Last Parsed: Loading...