js function to get filename from url February 2, 2023 by Tarik var filename = url.split("https://stackoverflow.com/").pop()