fileExt | R Documentation |
This function takes a file path or URL and returns the file extension.
Unlike functions like tools::file_ext
, this function handles both paths and URLs.
fileExt(text)
text |
Character. The full path or URL of the file. |
Character. The extension of the file. Returns an empty string if no extension is found.
fileExt("path/to/file.txt")
fileExt("https://example.com/file.csv")
fileExt("no_extension_file")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.