1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-25 09:38:54 -05:00
curl/docs/examples
2021-05-26 08:18:11 +02:00
..
.checksrc
.gitignore examples: update .gitignore 2020-11-23 23:09:33 +01:00
10-at-a-time.c
adddocsref.pl
altsvc.c
anyauthput.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
cacertinmem.c examples: remove superfluous asterisk uses 2020-12-16 09:24:16 +01:00
certinfo.c
chkspeed.c
cookie_interface.c
crawler.c
curlgtk.c examples/curlgtk.c: fix the copyright year range 2020-12-30 22:37:44 +01:00
curlx.c copyright: update copyright year ranges to 2021 2021-05-26 08:18:11 +02:00
debug.c
ephiperfifo.c
evhiperfifo.c
externalsocket.c tidy-up: make conditional checks more consistent 2021-04-22 09:10:17 +02:00
fileupload.c
fopen.c tidy-up: make conditional checks more consistent 2021-04-22 09:10:17 +02:00
ftp-wildcard.c
ftpget.c
ftpgetinfo.c
ftpgetresp.c
ftpsget.c
ftpupload.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
ftpuploadfrommem.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
ftpuploadresume.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
getinfo.c
getinmemory.c tidy-up: make conditional checks more consistent 2021-04-22 09:10:17 +02:00
getredirect.c
getreferrer.c http: add new files missed from referrer commit 2021-02-19 16:18:15 +00:00
ghiper.c
hiperfifo.c misc: update copyright year ranges to match latest updates 2021-04-13 14:32:30 +02:00
href_extractor.c
htmltidy.c
htmltitle.cpp
http2-download.c
http2-pushinmemory.c examples: fix more empty expression statement has no effect 2020-12-30 22:19:05 +01:00
http2-serverpush.c examples: fix more empty expression statement has no effect 2020-12-30 22:19:05 +01:00
http2-upload.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
http3-present.c
http3.c
http-post.c
httpcustomheader.c
httpput-postfields.c httpput-postfields.c: new example doing PUT with POSTFIELDS 2020-11-13 09:20:57 +01:00
httpput.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
https.c
imap-append.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
imap-authzid.c
imap-copy.c
imap-create.c
imap-delete.c
imap-examine.c
imap-fetch.c
imap-list.c
imap-lsub.c
imap-multi.c
imap-noop.c
imap-search.c
imap-ssl.c
imap-store.c
imap-tls.c
Makefile.am examples/libtest: add .checksrc to dist 2020-12-21 17:06:06 +01:00
makefile.dj
Makefile.example
Makefile.inc examples: Remove threaded-shared-conn.c due to bug 2021-03-26 03:14:50 -04:00
Makefile.m32 copyright: update copyright year ranges to 2021 2021-03-27 23:00:14 +01:00
Makefile.netware
multi-app.c
multi-debugcallback.c
multi-double.c
multi-event.c
multi-formadd.c
multi-poll.c
multi-post.c
multi-single.c cleanup: fix two empty expression statement has no effect 2020-12-30 16:58:19 +01:00
multi-uv.c
multithread.c
opensslthreadlock.c
parseurl.c
persistent.c
pop3-authzid.c
pop3-dele.c
pop3-list.c
pop3-multi.c
pop3-noop.c
pop3-retr.c
pop3-ssl.c
pop3-stat.c
pop3-tls.c
pop3-top.c
pop3-uidl.c
post-callback.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
postinmemory.c
postit2-formadd.c
postit2.c
progressfunc.c
README.md
resolve.c
rtsp.c tidy-up: make conditional checks more consistent 2021-04-22 09:10:17 +02:00
sampleconv.c
sendrecv.c
sepheaders.c
sessioninfo.c
sftpget.c
sftpuploadresume.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
shared-connection-cache.c
simple.c
simplepost.c
simplessl.c
smooth-gtk-thread.c
smtp-authzid.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
smtp-expn.c
smtp-mail.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
smtp-mime.c
smtp-multi.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
smtp-ssl.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
smtp-tls.c docs/examples: adjust prototypes for CURLOPT_READFUNCTION 2020-12-30 22:20:24 +01:00
smtp-vrfy.c examples: fix comment syntax 2020-11-05 09:54:12 +01:00
sslbackend.c
synctime.c examples: remove superfluous asterisk uses 2020-12-16 09:24:16 +01:00
threaded-ssl.c
url2file.c
urlapi.c
usercertinmem.c tidy-up: make conditional checks more consistent 2021-04-22 09:10:17 +02:00
version-check.pl
xmlstream.c

libcurl examples

This directory is for libcurl programming examples. They are meant to show some simple steps on how you can build your own application to take full advantage of libcurl.

If you end up with other small but still useful example sources, please mail them for submission in future packages and on the website.

Building

The Makefile.example is an example makefile that could be used to build these examples. Just edit the file according to your system and requirements first.

Most examples should build fine using a command line like this:

`curl-config --cc --cflags --libs` -o example example.c

Some compilers don't like having the arguments in this order but instead want you do reorganize them like:

`curl-config --cc` -o example example.c `curl-config --cflags --libs`

Please do not use the curl.se site as a test target for your libcurl applications/experiments. Even if some of the examples use that site as a URL at some places, it doesn't mean that the URLs work or that we expect you to actually torture our website with your tests! Thanks.

Examples

Each example source code file is designed to be and work stand-alone and rather self-explanatory. The examples may at times lack the level of error checks you need in a real world, but that is then only for the sake of readability: to make the code smaller and easier to follow.