Lowest price ever! Learn Generative AI for 48% less!
Get my discount0
1))
Use Ajax. And paste your code url into XMLHttpRequest.
2))
We will get a response data
Its my code. This code containe: how to access whole codes from a Sololearn profile
https://code.sololearn.com/Wxi8XFo2Q58H/?ref=app
Then
Use ZipJS library for compressing your codes.
ZipJS documentation:
https://gildas-lormeau.github.io/zip.js/
You can generate a zip file of any file type.
Then make a download link for that zip file
How to create a file downloader using JavaScript:
https://stackoverflow.com/questions/1066452/easiest-way-to-open-a-download-window-without-navigating-away-from-the-page