CURL
# curl http://www.centos.org - will display the content of the url
# curl http://www.centos.org > centos-org.html - will put the content of the url in the the file
# curl -o mygettext.html http://www.gnu.org/software/gettext/manual/gettext.html - saves the curl output into a file
# curl -O http://www.gnu.org/software/gettext/manual/gettext.html - the file name in the url will be used as the filename to store the output
# curl -O http://www.gnu.org/software/gettext/manual/html_node/index.html -O http://www.gnu.org/software/gettext/manual/gettext.html - will save multiple files at the same time
# curl -L http://www.google.com - will allow curl to follow http location headers (redirects)
# curl -C - -O http://www.gnu.org/software/gettext/manual/gettext.htm - allows curl to continue a previousl download
# curl --limit-rate 10000B -O http://gnu.org/software/gettext/manual/gettext.html - limits the rate of data transfer
# curl -z 21-Dec-11 http://www.example.com/yy.html - downloads a file only if it is modified before/after the date given
# curl -u username:password URL - pass http authentication in curl
# curl -u ftpuser:ftppass -O ftp://ftp_server/public_html/xss.php - download files from ftp server
# curl ftp://ftp.uk.debian.org/debian/pool/main/[a-z]/ - download using a range
# curl -u ftpuser:ftppass -T myfile.txt ftp://ftp.testserver.com - upload files to the FTP server
# curl -v http://google.co.in - retrieves more information using the verbose flag
# curl dict://dict.org/d:bash - uses curl to get the definition of a word
# curl -x proxyserver.test.com:3128 http://google.co.in - uses the proxy to download a file
# curl --mail-from blah@test.com --mail-rcpt foo@test.com smtp://mailserver.com - send mail using SMTP protocol
Last updated
Was this helpful?