cvs: phpdoc /fr/functions curl.xml
| From: | Damien Seguy | Date: | Tue, 21 Nov 2000 11:52:16 +0000 |
| Subject: | cvs: phpdoc /fr/functions curl.xml | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969333008@lists.php.net to get a copy of this message | ||
dams Tue Nov 21 03:52:16 2000 EDT
Modified files:
/phpdoc/fr/functions curl.xml
Log:
commit translation.
Index: phpdoc/fr/functions/curl.xml diff -u phpdoc/fr/functions/curl.xml:1.1 phpdoc/fr/functions/curl.xml:1.2 --- phpdoc/fr/functions/curl.xml:1.1 Fri Jul 28 02:03:45 2000 +++ phpdoc/fr/functions/curl.xml Tue Nov 21 03:52:16 2000 @@ -1,53 +1,51 @@ <reference id="ref.curl"> - <title>CURL, Client URL Library Functions</title> + <title>CURL</title> <titleabbrev>CURL</titleabbrev> - <partintro id="curl.partintro"> <para> - PHP supports libcurl, a library, created by Daniel Stenberg, that - allows you to connect and communicate to many different types of - servers with many different types of protocols. libcurl currently - supports the http, https, ftp, gopher, telnet, dict, file, and - ldap protocols. libcurl also supports HTTPS certificates, HTTP - POST, HTTP PUT, FTP uploading (this can also be done with PHP's - ftp extension), HTTP form based upload, proxies, cookies and - user+password authentication. + PHP supporte libcurl, une librairie créée par Daniel Stenberg, + qui vous permet de vous connecter de commniquer avec de nombreux serveurs, + grâce à de nombreux protocoles. libcurl supporte actuellement + les protocoles suivants : http, https, ftp, gopher, telnet, dict, file, et + ldap. libcurl supporte aussi les certificats HTTPS, les POST HTTP, PUT HTTP, + le chargement par FTP (ce qui peut être fait par l'extension FTP), + les chargement par formulaire HTTP, les proxies, les cookies et + l'autentification par mot de passe et nom de compte. </para> <para> - In order to use the CURL functions you need to install the <ulink - url="&url.curl;">CURL</ulink> package. PHP requires that you use - CURL 7.0.2-beta or higher. PHP will not work with any version of - CURL below version 7.0.2-beta. + Pour pouvoir utiliser les fonctions CURL, vous devez installer le + package <ulink url="&url.curl;">CURL</ulink>. PHP requiert la version + CURL 7.0.2-beta ou plus récente. PHP ne fonctionnera pas avec + une version inférieure à la version 7.0.2-beta. </para> <para> - To use PHP's CURL support you must also compile PHP <option - role="configure">--with-curl[=DIR]</option> where DIR is the - location of the directory containing the lib and include - directories. In the "include" directory there should be a folder - named "curl" which should contain the easy.h and curl.h files. - There should be a file named "libcurl.a" located in the "lib" - directory. + Pour utiliser CURL depuis les scripts PHP, vous devez aussi compiler PHP + avec l'option <option role="configure">--with-curl[=DIR]</option> + où DIR est le chemin jusqu'au dossier contenant les dossier + <filename>lib</filename> et <filename>include</filename>. Dans le + dossier <filename>include</filename> il doit se trouver un dossier + appelé <filename>curl</filename>, qui contient notamment les + fichiers <filename>easy.h</filename> et <filename>curl.h</filename>. + Il doit aussi se trouver un fichier nommé + <filename>libcurl.a</filename> dans le dossier <filename>lib</filename>. </para> <para> - Once you've compiled PHP with CURL support, you can begin using - the curl functions. The basic idea behind the CURL functions is - that you initialize a CURL session using the - <function>curl_init</function>, then you can set all your - options for the transfer via the <function>curl_exec</function> - and then you finish off your session using the - <function>curl_close</function>. Here is an example that uses - the CURL functions to fetch the PHP homepage into a file: + Une fois que vous avez compilé PHP avec le support CURL, vous + pouvez commencer à l'exploiter avec vos scripts PHP. Le principe + de fonctionnement est d'initialiser une session CURL avec + <function>curl_init</function>, puis de choisir toutes vos options + de transfert avec <function>curl_exec</function> et de finir votre + session avec <function>curl_close</function>. Voici un exemple + d'utilisation des fonctions CURL, qui récupère la + page principale de PHP : <example> - <title>Using PHP's CURL module to fetch the PHP homepage</title> + <title>Utilisation de CURL et PHP pour récupérer une page</title> <programlisting role="php"> <?php - $ch = curl_init ("http://www.php.net/"); $fp = fopen ("php_homepage.txt", "w"); - curl_setopt ($ch, CURLOPT_INFILE, $fp); curl_setopt ($ch, CURLOPT_HEADER, 0); - curl_exec ($ch); curl_close ($ch); fclose ($fp); @@ -56,20 +54,19 @@ </example> </para> </partintro> - <refentry id="function.curl-init"> <refnamediv> <refname>curl_init</refname> - <refpurpose>Initialize a CURL session</refpurpose> + <refpurpose>Initialise une session CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>int + <funcdef>int <function>curl_init</function> </funcdef> - <paramdef>string + <paramdef>string <parameter> <optional>url</optional> </parameter> @@ -77,343 +74,335 @@ </funcprototype> </funcsynopsis> <para> - The <function>curl_init</function> will initialize a new session - and return a CURL handle for use with the - <function>curl_setopt</function>, <function>curl_exec</function>, - and <function>curl_close</function> functions. If the optional - <parameter>url</parameter> parameter is supplied then the - CURLOPT_URL option will be set to the value of the parameter. - You can manually set this using the - <function>curl_setopt</function> function. + <function>curl_init</function> initialise une nouvelle session et retourne un + identifiant de session CURL, à utiliser avec les fonctions + <function>curl_setopt</function>, <function>curl_exec</function> + et <function>curl_close</function>. Si le paramètre optionnel + <parameter>url</parameter> est fourni, alors CURLOPT_URL prendra cette + valeur. Vous pouvez manuellement fixer cette valeur avec la fonction + <function>curl_setopt</function>. <example> <title> - Initializing a new CURL session and fetching a webpage + Initialiser une sessions CURL et récupèration d'une page web. </title> <programlisting role="php"> <?php $ch = curl_init(); - curl_setopt ($ch, CURLOPT_URL, "http://www.zend.com/"); curl_setopt ($ch, CURLOPT_HEADER, 0); - curl_exec ($ch); - curl_close ($ch); ?> </programlisting> </example> </para> <para> - See also: <function>curl_close</function>, - <function>curl_setopt</function> + Voir aussi : <function>curl_close</function>, <function>curl_setopt</function>. </para> </refsect1> </refentry> - <refentry id="function.curl-setopt"> <refnamediv> <refname>curl_setopt</refname> - <refpurpose>Set an option for a CURL transfer</refpurpose> + <refpurpose>Modifie une option de transfert CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>bool + <funcdef>bool <function>curl_setopt</function> </funcdef> - <paramdef>int + <paramdef>int <parameter>ch</parameter> </paramdef> - <paramdef>string + <paramdef>string <parameter>option</parameter> </paramdef> - <paramdef>mixed + <paramdef>mixed <parameter>value</parameter> </paramdef> </funcprototype> </funcsynopsis> <para> - The <function>curl_setopt</function> function will set options - for a CURL session identified by the <parameter>ch</parameter> - parameter. The <parameter>option</parameter> parameter is the - option you want to set, and the <parameter>value</parameter> is - the value of the option given by the - <parameter>option</parameter>. + <function>curl_setopt</function> fixe les options de transfert de la + session CURL identifiée par <parameter>ch</parameter>. + <parameter>option</parameter> est le nom de l'option à fixer, + et <parameter>value</parameter> est sa valeur. </para> <para> - The <parameter>value</parameter> should be a long for the - following options (specified in the <parameter>option</parameter> - parameter): + <parameter>value</parameter> doit être de type "long" pour + les options suivantes (specifiée par <parameter>option</parameter>) : <itemizedlist> <listitem> <simpara> - <parameter>CURLOPT_INFILESIZE</parameter>: When you are - uploading a file to a remote site, this option should be used - to tell PHP what the expected size of the infile will be. + <parameter>CURLOPT_INFILESIZE</parameter>: Lorsque vous + téléchargez un fichier sur un site distant, cette + option sert à indiquer à PHP la taille maximale du + fichier attendu. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_VERBOSE</parameter>: Set this option to a - non-zero value if you want CURL to report everything that is - happening. + <parameter>CURLOPT_VERBOSE</parameter>: Choississez une valeur non nulle + pour que CURL vous affiche tous les événements. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_HEADER</parameter>: Set this option to a - non-zero value if you want the header to be included in the - output. + <parameter>CURLOPT_HEADER</parameter>: Choississez une valeur non nulle + pour que CURL inclus l'entête dans la valeur de retour. </simpara> </listitem> <listitem> <para> - <parameter>CURLOPT_NOPROGRESS</parameter>: Set this option to - a non-zero value if you don't want PHP to display a progress - meter for CURL transfers + <parameter>CURLOPT_NOPROGRESS</parameter>: Choississez une valeur non nulle + pour que PHP n'affiche pas l'état des transferts CURL. <note> <simpara> - PHP automatically sets this option to a non-zero parameter, - this should only be changed for debugging purposes. + PHP choisit automatiquement une valeur non nulle. Ne changez cette valeur + que le temps du débuggage. </simpara> </note> </para> </listitem> <listitem> <simpara> - <parameter>CURLOPT_NOBODY</parameter>: Set this option to a - non-zero value if you don't want the body included with the - output. + <parameter>CURLOPT_NOBODY</parameter>: Choississez une valeur non nulle + pour que le corps du transfert ne soit pas inclus dans la valeur de retour. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FAILONERROR</parameter>: Set this option to - a non-zero value if you want PHP to fail silently if the HTTP - code returned is greater than 300. The default behaviour is - to return the page normally, ignoring the code. + <parameter>CURLOPT_FAILONERROR</parameter>: Choississez une valeur non nulle + pour que PHP traite silencieusement les codes HTTP supérieurs + à 300. Le comportement par défaut est de retourner la + page normalement, en ignorant ce code. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_UPLOAD</parameter>: Set this option to a - non-zero value if you want PHP to prepare for an upload. + <parameter>CURLOPT_UPLOAD</parameter>: Choississez une valeur non nulle + pour que PHP prépare un chargement. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_POST</parameter>: Set this option to a - non-zero value if you want PHP to do a regular HTTP POST. - This POST is a normal application/x-www-from-urlencoded kind, - most commonly used by HTML forms. + <parameter>CURLOPT_POST</parameter>: Choississez une valeur non nulle + pour que PHP fasse un HTTP POST. Un POST est un encodage normal + "application/x-www-from-url", utilisé couramment par les formulaires + HTML. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FTPLISTONLY</parameter>: Set this option to - a non-zero value and PHP will just list the names of an FTP - directory. + <parameter>CURLOPT_FTPLISTONLY</parameter>: Choississez une valeur non nulle + pour que PHP ne fasse que lister les noms d'un dossier FTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FTPAPPEND</parameter>: Set this option to a - non-zero value and PHP will append to the remote file instead - of overwriting it. + <parameter>CURLOPT_FTPAPPEND</parameter>: Choississez une valeur non nulle + pour que PHP concatène le fichier distant, plutôt que de + l'écraser. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_NETRC</parameter>: Set this option to a - non-zero value and PHP will scan your ~./netrc file to find - your username and password for the remote site that you're - establishing a connection with. + <parameter>CURLOPT_NETRC</parameter>: Choississez une valeur non nulle + pour que PHP scanne votre fichier ~./netrc et utilise votre nom de + compte et mot de passe sur le site distant que vous souhaitez contacter. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FOLLOWLOCATION</parameter>: Set this option - to a non-zero value to follow any "Location: " header that the - server sends as a part of the HTTP header (note this is - recursive, PHP will follow as many "Location: " headers that - it is sent.) + <parameter>CURLOPT_FOLLOWLOCATION</parameter>: Choississez une valeur + non nulle pour suivre toutes les entêtes "Location: " que le + serveur envoie dans les entêtes HTTP (notez que cette fonction + est récursive, et que PHP suivra toutes les entêtes + "Location: " qu'il trouvera). </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_PUT</parameter>: Set this option a non-zero - value to HTTP PUT a file. The file to PUT must be set with - the CURLOPT_INFILE and CURLOPT_INFILESIZE. + <parameter>CURLOPT_PUT</parameter>: Choississez une valeur non nulle + pour que pour chargement se fasse par HTTP PUT. Le fichier à + charger doit être fixé avec les options CURLOPT_INFILE + et CURLOPT_INFILESIZE. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_MUTE</parameter>: Set this option to a - non-zero value and PHP will be completely silent with regards - to the CURL functions. + <parameter>CURLOPT_MUTE</parameter>: Choississez une valeur non nulle + pour que PHP soit totalement silencieux concernant toutes les fonctions + CURL. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_TIMEOUT</parameter>: Pass a long as a - parameter that contains the maximum time, in seconds, that - you'll allow the curl functions to take. + <parameter>CURLOPT_TIMEOUT</parameter>: Passez un entier "long" comme + paramètre qui représente le temps maximum d'exécution + de la fonction CURL. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_LOW_SPEED_LIMIT</parameter>: Pass a long as - a parameter that contains the transfer speed in bytes per - second that the transfer should be below during - CURLOPT_LOW_SPEED_TIME seconds for PHP to consider it too slow - and abort. + <parameter>CURLOPT_LOW_SPEED_LIMIT</parameter>: Passez un entier long + qui représente la vitesse minimale en octets par secondes en + dessous de laquelle, et pendant CURLOPT_LOW_SPEED secondes, PHP + considèrera qu'elle est trop lente, et annulera le transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_LOW_SPEED_TIME</parameter>: Pass a long as - a parameter that contains the time in seconds that the - transfer should be below the CURLOPT_LOW_SPEED_LIMIT for PHP - to consider it too slow and abort. + <parameter>CURLOPT_LOW_SPEED_TIME</parameter>: Passez un entier "long" + qui représente le temps en secondes, qui, si la vitesse de + transfert reste en dessous de CURLOPT_LOW_SPEED_LIMIT, PHP + considèrera que la connexion est trop lente, et l'annulera. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_RESUME_FROM</parameter>: Pass a long as a - parameter that contains the offset, in bytes, that you want - the transfer to start from. + <parameter>CURLOPT_RESUME_FROM</parameter>: Passez un entier "long", + qui représente l'offset, en octets, à partir duquel vous voulez + commencer le transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_SSLVERSION</parameter>: Pass a long as a - parameter that contains the SSL version (2 or 3) to use. By - default PHP will try and determine this by itself, although, - in some cases you must set this manually. + <parameter>CURLOPT_SSLVERSION</parameter>: Passez un entier "long" + qui contient la version de SSL (2 ou 3) à utiliser. Par + défaut, PHP essaiera de le déterminer par + lui-même, bien que dans certains cas, il vous faudra + le faire manuellement. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_TIMECONDITION</parameter>: Pass a long as a - parameter that defines how the CURLOPT_TIMEVALUE is treated. - You can set this parameter to TIMECOND_IFMODSINCE or - TIMECOND_ISUNMODSINCE. This is a HTTP-only feature. + <parameter>CURLOPT_TIMECONDITION</parameter>: Passez un entier "long" + qui définit comment CURLOPT_TIMEVALUE est utilisé. + Vous pouvez choisir entre les valeurs TIMECOND_IFMODSINCE ou + TIMECOND_ISUNMODSINCE. C'est une fonctionnalité HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_TIMEVALUE</parameter>: Pass a long as a - parameter that is the time in seconds since January 1st, 1970. - The time will be used as specified by the CURLOPT_TIMEVALUE - option, or by default the TIMECOND_IFMODSINCE will be used. + <parameter>CURLOPT_TIMEVALUE</parameter>: Passez un entier "long" + qui représente le temps en secondes depuis le 1er janvier 1970. + Cette valeur sera utilisée comme spécifié dans + l'option CURLOPT_TIMEVALUE. Par défaut, TIMECOND_IFMODSINCE + sera utilisé. </simpara> </listitem> </itemizedlist> </para> <para> - The <parameter>value</parameter> parameter should be a string for - the following values of the <parameter>option</parameter> - parameter: + <parameter>value</parameter> doit être une chaîne de + caractères pour les valeurs suivantes de <parameter>option</parameter> <itemizedlist> <listitem> <simpara> - <parameter>CURLOPT_URL</parameter>: This is the URL that you - want PHP to fetch. You can also set this option when - initializing a session with the <function>curl_init</function> + <parameter>CURLOPT_URL</parameter>: L'URL que PHP va récupérer. + Vous pouvez aussi choisir cette v aleur lors de l'appel à + <function>curl_init</function>. function. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_USERPWD</parameter>: Pass a string - formatted in the [username]:[password] manner, for PHP to use - for the connection. connection. + <parameter>CURLOPT_USERPWD</parameter>: Passez une chaîne de + caractères au format [nom]:[mot de passe], pour que PHP + l'utilise lors de la connexion. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_PROXYUSERPWD</parameter>: Pass a string - formatted in the [username]:[password] format for connection - to the HTTP proxy. + <parameter>CURLOPT_PROXYUSERPWD</parameter>: Passez une chaîne + de caractères au format [nom]:[mot de passe ], pour que PHP + l'utilise lors de la connexion à un proxy HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_RANGE</parameter>: Pass the specified range - you want. It should be in the "X-Y" format, where X or Y may - be left out. The HTTP transfers also support several - intervals, seperated with commas as in X-Y,N-M. + <parameter>CURLOPT_RANGE</parameter>: Passez une chaîne de + caractères qui représente la plage de valeur que + vous désirez. Elle est au format "X-Y", où les + valeurs de X ou Y peuvent être omises. Le transfert HTTP + supporte aussi plusieurs intervalles, séparé par + des virgules : X-Y,N-M. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_POSTFIELDS</parameter>: Pass a string - containing the full data to post in an HTTP "POST" operation. + <parameter>CURLOPT_POSTFIELDS</parameter>: Passez une chaîne + de caractères qui contient toutes les données à + passer lors d'une opération de HTTP POST. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_REFERER</parameter>: Pass a string - containing the "referer" header to be used in an HTTP request. + <parameter>CURLOPT_REFERER</parameter>: Passez une chaîne de + caractères qui contient l'entête de "REFERER", + utilisé lors d'une requête HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_USERAGENT</parameter>: Pass a string - containing the "user-agent" header to be used in an HTTP - request. + <parameter>CURLOPT_USERAGENT</parameter>: Passez une chaîne + de caractères qui contient l'entête "user-agent" + utilisé dans une requête HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FTPPORT</parameter>: Pass a string - containing the which will be used to get the IP address to use - for the ftp "PORT" instruction. The POST instruction tells - the remote server to connect to our specified IP address. The - string may be a plain IP address, a hostname, a network - interface name (under UNIX), or just a plain '-' to use the - systems default IP address. + <parameter>CURLOPT_FTPPORT</parameter>: Passez une chaîne de + caractères qui désignera l'adresse IP utilisée + pour l'instruction FTP "PORT". L'instruction POST indique au serveur + distant de se connecter cette adresse IP. La chaîne peut + être une adresse IP, un nom d'hôte, un nom d'interface + réseau (sous UNIX), ou juste '-', pour utiliser les IP par + défaut du système. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_COOKIE</parameter>: Pass a string - containing the content of the cookie to be set in the HTTP - header. + <parameter>CURLOPT_COOKIE</parameter>: Passez une chaîne de + caractères qui contiendra le contenu du cookie, à + transmettre dans l'entête HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_SSLCERT</parameter>: Pass a string - containing the filename of PEM formatted certificate. + <parameter>CURLOPT_SSLCERT</parameter>: Passez une chaîne de + caractères qui contiendra le nom de fichier du certificat, + au format PEM. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_SSLCERTPASSWD</parameter>: Pass a string - containing the password required to use the CURLOPT_SSLCERT - certificate. + <parameter>CURLOPT_SSLCERTPASSWD</parameter>: Passez une chaîne + de caractères qui contient le mot de passe nécessaire + pour utiliser le certificat CURLOPT_SSLCERT. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_COOKIEFILE</parameter>: Pass a string - containing the name of the file containing the cookiee data. - The cookie file can be in Netscape format, or just plain - HTTP-style headers dumped into a file. + <parameter>CURLOPT_COOKIEFILE</parameter>: Passez une chaîne de + caractères qui contiendra le nom du fichier contenant les + données de cookie. Le fichier de cookie peut être au + format Netscape, ou simplement des entêtes HTTP écrites + dans un fichier. </simpara> </listitem> <listitem> <para> - <parameter>CURLOPT_CUSTOMREQUEST</parameter>: Pass a string to - be used instead of GET or HEAD when doing an HTTP request. - This is useful for doing DELETE or another, more obscure, HTTP - request. + <parameter>CURLOPT_CUSTOMREQUEST</parameter>: Passez une chaîne + de caractères qui sera utilisé à la place de GET + ou HEAD lors des requêtes HTTP. Cette commande est pratique pour + effectuer un DELETE, ou une autre commande HTTP exotique. <note> <simpara> - Don't do this without making sure your server supports the - command first. + N'utilisez pas cette commande sans vous assurer que le serveur l'accepte. </simpara> </note> </para> @@ -421,111 +410,107 @@ </itemizedlist> </para> <para> - The following options expect a file descriptor that is obtained - by using the <function>fopen</function> function: + Les options suivantes requièrent un pointeur de fichier, qui est + obtenu avec la fonction <function>fopen</function> : <itemizedlist> <listitem> <simpara> - <parameter>CURLOPT_FILE</parameter>: The file where the output - of your transfer should be placed, the default is STDOUT. + <parameter>CURLOPT_FILE</parameter>: Le fichier de sortie de votre transfert. + Par défaut, STDOUT. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_INFILE</parameter>: The file where the - input of your transfer comes from. + <parameter>CURLOPT_INFILE</parameter>: Le fichier d'entrée de + votre transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_WRITEHEADER</parameter>: The file to write - the header part of the output into. + <parameter>CURLOPT_WRITEHEADER</parameter>: Le fichier de destination + de l'entête de la sortie du transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_STDERR</parameter>: The file to write - errors to instead of stderr. + <parameter>CURLOPT_STDERR</parameter>: Le fichier d'erreurs. </simpara> </listitem> </itemizedlist> </para> </refsect1> </refentry> - <refentry id="function.curl-exec"> <refnamediv> <refname>curl_exec</refname> - <refpurpose>Perform a CURL session</refpurpose> + <refpurpose>Excécute une session CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>bool + <funcdef>bool <function>curl_exec</function> </funcdef> - <paramdef>int + <paramdef>int <parameter>ch</parameter> </paramdef> </funcprototype> </funcsynopsis> <para> - This function is should be called after you initialize a CURL - session and all the options for the session are set. Its purpose - is simply to execute the predefined CURL session (given by the - <parameter>ch</parameter>). + Cette fonction doit être appelée après + l'initialisation et le paramètrage d'une session CURL. + Son but est simplement d'éxécuter la session + <parameter>ch</parameter>. </para> </refsect1> </refentry> - <refentry id="function.curl-close"> <refnamediv> <refname>curl_close</refname> - <refpurpose>Close a CURL session</refpurpose> + <refpurpose>Ferme une session CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>void + <funcdef>void <function>curl_close</function> </funcdef> - <paramdef>int + <paramdef>int <parameter>ch</parameter> </paramdef> </funcprototype> </funcsynopsis> <para> - This functions closes a CURL session and frees all ressources. - The CURL handle, <parameter>ch</parameter>, is also deleted. + Cette fonction ferme une session CURL et libère + toutes les ressources reservées. L'identifiant CURL, + <parameter>ch</parameter>, est aussi effacé. </para> </refsect1> </refentry> - <refentry id="function.curl-version"> <refnamediv> <refname>curl_version</refname> - <refpurpose>Return the current CURL version</refpurpose> + <refpurpose>Retourne la version courante de CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>string + <funcdef>string <function>curl_version</function> </funcdef> <void/> </funcprototype> </funcsynopsis> <para> - The <function>curl_version</function> function returns a string - containing the current CURL version. + <function>curl_version</function> retourne une chaîne + avec la version courante de la librairie CURL. </para> </refsect1> </refentry> </reference> - <!-- Keep this comment at the end of the file Local variables: mode: sgml
Index: phpdoc/fr/functions/curl.xml diff -u phpdoc/fr/functions/curl.xml:1.1 phpdoc/fr/functions/curl.xml:1.2 --- phpdoc/fr/functions/curl.xml:1.1 Fri Jul 28 02:03:45 2000 +++ phpdoc/fr/functions/curl.xml Tue Nov 21 03:52:16 2000 @@ -1,53 +1,51 @@ <reference id="ref.curl"> - <title>CURL, Client URL Library Functions</title> + <title>CURL</title> <titleabbrev>CURL</titleabbrev> - <partintro id="curl.partintro"> <para> - PHP supports libcurl, a library, created by Daniel Stenberg, that - allows you to connect and communicate to many different types of - servers with many different types of protocols. libcurl currently - supports the http, https, ftp, gopher, telnet, dict, file, and - ldap protocols. libcurl also supports HTTPS certificates, HTTP - POST, HTTP PUT, FTP uploading (this can also be done with PHP's - ftp extension), HTTP form based upload, proxies, cookies and - user+password authentication. + PHP supporte libcurl, une librairie créée par Daniel Stenberg, + qui vous permet de vous connecter de commniquer avec de nombreux serveurs, + grâce à de nombreux protocoles. libcurl supporte actuellement + les protocoles suivants : http, https, ftp, gopher, telnet, dict, file, et + ldap. libcurl supporte aussi les certificats HTTPS, les POST HTTP, PUT HTTP, + le chargement par FTP (ce qui peut être fait par l'extension FTP), + les chargement par formulaire HTTP, les proxies, les cookies et + l'autentification par mot de passe et nom de compte. </para> <para> - In order to use the CURL functions you need to install the <ulink - url="&url.curl;">CURL</ulink> package. PHP requires that you use - CURL 7.0.2-beta or higher. PHP will not work with any version of - CURL below version 7.0.2-beta. + Pour pouvoir utiliser les fonctions CURL, vous devez installer le + package <ulink url="&url.curl;">CURL</ulink>. PHP requiert la version + CURL 7.0.2-beta ou plus récente. PHP ne fonctionnera pas avec + une version inférieure à la version 7.0.2-beta. </para> <para> - To use PHP's CURL support you must also compile PHP <option - role="configure">--with-curl[=DIR]</option> where DIR is the - location of the directory containing the lib and include - directories. In the "include" directory there should be a folder - named "curl" which should contain the easy.h and curl.h files. - There should be a file named "libcurl.a" located in the "lib" - directory. + Pour utiliser CURL depuis les scripts PHP, vous devez aussi compiler PHP + avec l'option <option role="configure">--with-curl[=DIR]</option> + où DIR est le chemin jusqu'au dossier contenant les dossier + <filename>lib</filename> et <filename>include</filename>. Dans le + dossier <filename>include</filename> il doit se trouver un dossier + appelé <filename>curl</filename>, qui contient notamment les + fichiers <filename>easy.h</filename> et <filename>curl.h</filename>. + Il doit aussi se trouver un fichier nommé + <filename>libcurl.a</filename> dans le dossier <filename>lib</filename>. </para> <para> - Once you've compiled PHP with CURL support, you can begin using - the curl functions. The basic idea behind the CURL functions is - that you initialize a CURL session using the - <function>curl_init</function>, then you can set all your - options for the transfer via the <function>curl_exec</function> - and then you finish off your session using the - <function>curl_close</function>. Here is an example that uses - the CURL functions to fetch the PHP homepage into a file: + Une fois que vous avez compilé PHP avec le support CURL, vous + pouvez commencer à l'exploiter avec vos scripts PHP. Le principe + de fonctionnement est d'initialiser une session CURL avec + <function>curl_init</function>, puis de choisir toutes vos options + de transfert avec <function>curl_exec</function> et de finir votre + session avec <function>curl_close</function>. Voici un exemple + d'utilisation des fonctions CURL, qui récupère la + page principale de PHP : <example> - <title>Using PHP's CURL module to fetch the PHP homepage</title> + <title>Utilisation de CURL et PHP pour récupérer une page</title> <programlisting role="php"> <?php - $ch = curl_init ("http://www.php.net/"); $fp = fopen ("php_homepage.txt", "w"); - curl_setopt ($ch, CURLOPT_INFILE, $fp); curl_setopt ($ch, CURLOPT_HEADER, 0); - curl_exec ($ch); curl_close ($ch); fclose ($fp); @@ -56,20 +54,19 @@ </example> </para> </partintro> - <refentry id="function.curl-init"> <refnamediv> <refname>curl_init</refname> - <refpurpose>Initialize a CURL session</refpurpose> + <refpurpose>Initialise une session CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>int + <funcdef>int <function>curl_init</function> </funcdef> - <paramdef>string + <paramdef>string <parameter> <optional>url</optional> </parameter> @@ -77,343 +74,335 @@ </funcprototype> </funcsynopsis> <para> - The <function>curl_init</function> will initialize a new session - and return a CURL handle for use with the - <function>curl_setopt</function>, <function>curl_exec</function>, - and <function>curl_close</function> functions. If the optional - <parameter>url</parameter> parameter is supplied then the - CURLOPT_URL option will be set to the value of the parameter. - You can manually set this using the - <function>curl_setopt</function> function. + <function>curl_init</function> initialise une nouvelle session et retourne un + identifiant de session CURL, à utiliser avec les fonctions + <function>curl_setopt</function>, <function>curl_exec</function> + et <function>curl_close</function>. Si le paramètre optionnel + <parameter>url</parameter> est fourni, alors CURLOPT_URL prendra cette + valeur. Vous pouvez manuellement fixer cette valeur avec la fonction + <function>curl_setopt</function>. <example> <title> - Initializing a new CURL session and fetching a webpage + Initialiser une sessions CURL et récupèration d'une page web. </title> <programlisting role="php"> <?php $ch = curl_init(); - curl_setopt ($ch, CURLOPT_URL, "http://www.zend.com/"); curl_setopt ($ch, CURLOPT_HEADER, 0); - curl_exec ($ch); - curl_close ($ch); ?> </programlisting> </example> </para> <para> - See also: <function>curl_close</function>, - <function>curl_setopt</function> + Voir aussi : <function>curl_close</function>, <function>curl_setopt</function>. </para> </refsect1> </refentry> - <refentry id="function.curl-setopt"> <refnamediv> <refname>curl_setopt</refname> - <refpurpose>Set an option for a CURL transfer</refpurpose> + <refpurpose>Modifie une option de transfert CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>bool + <funcdef>bool <function>curl_setopt</function> </funcdef> - <paramdef>int + <paramdef>int <parameter>ch</parameter> </paramdef> - <paramdef>string + <paramdef>string <parameter>option</parameter> </paramdef> - <paramdef>mixed + <paramdef>mixed <parameter>value</parameter> </paramdef> </funcprototype> </funcsynopsis> <para> - The <function>curl_setopt</function> function will set options - for a CURL session identified by the <parameter>ch</parameter> - parameter. The <parameter>option</parameter> parameter is the - option you want to set, and the <parameter>value</parameter> is - the value of the option given by the - <parameter>option</parameter>. + <function>curl_setopt</function> fixe les options de transfert de la + session CURL identifiée par <parameter>ch</parameter>. + <parameter>option</parameter> est le nom de l'option à fixer, + et <parameter>value</parameter> est sa valeur. </para> <para> - The <parameter>value</parameter> should be a long for the - following options (specified in the <parameter>option</parameter> - parameter): + <parameter>value</parameter> doit être de type "long" pour + les options suivantes (specifiée par <parameter>option</parameter>) : <itemizedlist> <listitem> <simpara> - <parameter>CURLOPT_INFILESIZE</parameter>: When you are - uploading a file to a remote site, this option should be used - to tell PHP what the expected size of the infile will be. + <parameter>CURLOPT_INFILESIZE</parameter>: Lorsque vous + téléchargez un fichier sur un site distant, cette + option sert à indiquer à PHP la taille maximale du + fichier attendu. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_VERBOSE</parameter>: Set this option to a - non-zero value if you want CURL to report everything that is - happening. + <parameter>CURLOPT_VERBOSE</parameter>: Choississez une valeur non nulle + pour que CURL vous affiche tous les événements. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_HEADER</parameter>: Set this option to a - non-zero value if you want the header to be included in the - output. + <parameter>CURLOPT_HEADER</parameter>: Choississez une valeur non nulle + pour que CURL inclus l'entête dans la valeur de retour. </simpara> </listitem> <listitem> <para> - <parameter>CURLOPT_NOPROGRESS</parameter>: Set this option to - a non-zero value if you don't want PHP to display a progress - meter for CURL transfers + <parameter>CURLOPT_NOPROGRESS</parameter>: Choississez une valeur non nulle + pour que PHP n'affiche pas l'état des transferts CURL. <note> <simpara> - PHP automatically sets this option to a non-zero parameter, - this should only be changed for debugging purposes. + PHP choisit automatiquement une valeur non nulle. Ne changez cette valeur + que le temps du débuggage. </simpara> </note> </para> </listitem> <listitem> <simpara> - <parameter>CURLOPT_NOBODY</parameter>: Set this option to a - non-zero value if you don't want the body included with the - output. + <parameter>CURLOPT_NOBODY</parameter>: Choississez une valeur non nulle + pour que le corps du transfert ne soit pas inclus dans la valeur de retour. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FAILONERROR</parameter>: Set this option to - a non-zero value if you want PHP to fail silently if the HTTP - code returned is greater than 300. The default behaviour is - to return the page normally, ignoring the code. + <parameter>CURLOPT_FAILONERROR</parameter>: Choississez une valeur non nulle + pour que PHP traite silencieusement les codes HTTP supérieurs + à 300. Le comportement par défaut est de retourner la + page normalement, en ignorant ce code. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_UPLOAD</parameter>: Set this option to a - non-zero value if you want PHP to prepare for an upload. + <parameter>CURLOPT_UPLOAD</parameter>: Choississez une valeur non nulle + pour que PHP prépare un chargement. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_POST</parameter>: Set this option to a - non-zero value if you want PHP to do a regular HTTP POST. - This POST is a normal application/x-www-from-urlencoded kind, - most commonly used by HTML forms. + <parameter>CURLOPT_POST</parameter>: Choississez une valeur non nulle + pour que PHP fasse un HTTP POST. Un POST est un encodage normal + "application/x-www-from-url", utilisé couramment par les formulaires + HTML. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FTPLISTONLY</parameter>: Set this option to - a non-zero value and PHP will just list the names of an FTP - directory. + <parameter>CURLOPT_FTPLISTONLY</parameter>: Choississez une valeur non nulle + pour que PHP ne fasse que lister les noms d'un dossier FTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FTPAPPEND</parameter>: Set this option to a - non-zero value and PHP will append to the remote file instead - of overwriting it. + <parameter>CURLOPT_FTPAPPEND</parameter>: Choississez une valeur non nulle + pour que PHP concatène le fichier distant, plutôt que de + l'écraser. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_NETRC</parameter>: Set this option to a - non-zero value and PHP will scan your ~./netrc file to find - your username and password for the remote site that you're - establishing a connection with. + <parameter>CURLOPT_NETRC</parameter>: Choississez une valeur non nulle + pour que PHP scanne votre fichier ~./netrc et utilise votre nom de + compte et mot de passe sur le site distant que vous souhaitez contacter. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FOLLOWLOCATION</parameter>: Set this option - to a non-zero value to follow any "Location: " header that the - server sends as a part of the HTTP header (note this is - recursive, PHP will follow as many "Location: " headers that - it is sent.) + <parameter>CURLOPT_FOLLOWLOCATION</parameter>: Choississez une valeur + non nulle pour suivre toutes les entêtes "Location: " que le + serveur envoie dans les entêtes HTTP (notez que cette fonction + est récursive, et que PHP suivra toutes les entêtes + "Location: " qu'il trouvera). </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_PUT</parameter>: Set this option a non-zero - value to HTTP PUT a file. The file to PUT must be set with - the CURLOPT_INFILE and CURLOPT_INFILESIZE. + <parameter>CURLOPT_PUT</parameter>: Choississez une valeur non nulle + pour que pour chargement se fasse par HTTP PUT. Le fichier à + charger doit être fixé avec les options CURLOPT_INFILE + et CURLOPT_INFILESIZE. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_MUTE</parameter>: Set this option to a - non-zero value and PHP will be completely silent with regards - to the CURL functions. + <parameter>CURLOPT_MUTE</parameter>: Choississez une valeur non nulle + pour que PHP soit totalement silencieux concernant toutes les fonctions + CURL. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_TIMEOUT</parameter>: Pass a long as a - parameter that contains the maximum time, in seconds, that - you'll allow the curl functions to take. + <parameter>CURLOPT_TIMEOUT</parameter>: Passez un entier "long" comme + paramètre qui représente le temps maximum d'exécution + de la fonction CURL. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_LOW_SPEED_LIMIT</parameter>: Pass a long as - a parameter that contains the transfer speed in bytes per - second that the transfer should be below during - CURLOPT_LOW_SPEED_TIME seconds for PHP to consider it too slow - and abort. + <parameter>CURLOPT_LOW_SPEED_LIMIT</parameter>: Passez un entier long + qui représente la vitesse minimale en octets par secondes en + dessous de laquelle, et pendant CURLOPT_LOW_SPEED secondes, PHP + considèrera qu'elle est trop lente, et annulera le transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_LOW_SPEED_TIME</parameter>: Pass a long as - a parameter that contains the time in seconds that the - transfer should be below the CURLOPT_LOW_SPEED_LIMIT for PHP - to consider it too slow and abort. + <parameter>CURLOPT_LOW_SPEED_TIME</parameter>: Passez un entier "long" + qui représente le temps en secondes, qui, si la vitesse de + transfert reste en dessous de CURLOPT_LOW_SPEED_LIMIT, PHP + considèrera que la connexion est trop lente, et l'annulera. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_RESUME_FROM</parameter>: Pass a long as a - parameter that contains the offset, in bytes, that you want - the transfer to start from. + <parameter>CURLOPT_RESUME_FROM</parameter>: Passez un entier "long", + qui représente l'offset, en octets, à partir duquel vous voulez + commencer le transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_SSLVERSION</parameter>: Pass a long as a - parameter that contains the SSL version (2 or 3) to use. By - default PHP will try and determine this by itself, although, - in some cases you must set this manually. + <parameter>CURLOPT_SSLVERSION</parameter>: Passez un entier "long" + qui contient la version de SSL (2 ou 3) à utiliser. Par + défaut, PHP essaiera de le déterminer par + lui-même, bien que dans certains cas, il vous faudra + le faire manuellement. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_TIMECONDITION</parameter>: Pass a long as a - parameter that defines how the CURLOPT_TIMEVALUE is treated. - You can set this parameter to TIMECOND_IFMODSINCE or - TIMECOND_ISUNMODSINCE. This is a HTTP-only feature. + <parameter>CURLOPT_TIMECONDITION</parameter>: Passez un entier "long" + qui définit comment CURLOPT_TIMEVALUE est utilisé. + Vous pouvez choisir entre les valeurs TIMECOND_IFMODSINCE ou + TIMECOND_ISUNMODSINCE. C'est une fonctionnalité HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_TIMEVALUE</parameter>: Pass a long as a - parameter that is the time in seconds since January 1st, 1970. - The time will be used as specified by the CURLOPT_TIMEVALUE - option, or by default the TIMECOND_IFMODSINCE will be used. + <parameter>CURLOPT_TIMEVALUE</parameter>: Passez un entier "long" + qui représente le temps en secondes depuis le 1er janvier 1970. + Cette valeur sera utilisée comme spécifié dans + l'option CURLOPT_TIMEVALUE. Par défaut, TIMECOND_IFMODSINCE + sera utilisé. </simpara> </listitem> </itemizedlist> </para> <para> - The <parameter>value</parameter> parameter should be a string for - the following values of the <parameter>option</parameter> - parameter: + <parameter>value</parameter> doit être une chaîne de + caractères pour les valeurs suivantes de <parameter>option</parameter> <itemizedlist> <listitem> <simpara> - <parameter>CURLOPT_URL</parameter>: This is the URL that you - want PHP to fetch. You can also set this option when - initializing a session with the <function>curl_init</function> + <parameter>CURLOPT_URL</parameter>: L'URL que PHP va récupérer. + Vous pouvez aussi choisir cette v aleur lors de l'appel à + <function>curl_init</function>. function. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_USERPWD</parameter>: Pass a string - formatted in the [username]:[password] manner, for PHP to use - for the connection. connection. + <parameter>CURLOPT_USERPWD</parameter>: Passez une chaîne de + caractères au format [nom]:[mot de passe], pour que PHP + l'utilise lors de la connexion. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_PROXYUSERPWD</parameter>: Pass a string - formatted in the [username]:[password] format for connection - to the HTTP proxy. + <parameter>CURLOPT_PROXYUSERPWD</parameter>: Passez une chaîne + de caractères au format [nom]:[mot de passe ], pour que PHP + l'utilise lors de la connexion à un proxy HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_RANGE</parameter>: Pass the specified range - you want. It should be in the "X-Y" format, where X or Y may - be left out. The HTTP transfers also support several - intervals, seperated with commas as in X-Y,N-M. + <parameter>CURLOPT_RANGE</parameter>: Passez une chaîne de + caractères qui représente la plage de valeur que + vous désirez. Elle est au format "X-Y", où les + valeurs de X ou Y peuvent être omises. Le transfert HTTP + supporte aussi plusieurs intervalles, séparé par + des virgules : X-Y,N-M. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_POSTFIELDS</parameter>: Pass a string - containing the full data to post in an HTTP "POST" operation. + <parameter>CURLOPT_POSTFIELDS</parameter>: Passez une chaîne + de caractères qui contient toutes les données à + passer lors d'une opération de HTTP POST. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_REFERER</parameter>: Pass a string - containing the "referer" header to be used in an HTTP request. + <parameter>CURLOPT_REFERER</parameter>: Passez une chaîne de + caractères qui contient l'entête de "REFERER", + utilisé lors d'une requête HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_USERAGENT</parameter>: Pass a string - containing the "user-agent" header to be used in an HTTP - request. + <parameter>CURLOPT_USERAGENT</parameter>: Passez une chaîne + de caractères qui contient l'entête "user-agent" + utilisé dans une requête HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_FTPPORT</parameter>: Pass a string - containing the which will be used to get the IP address to use - for the ftp "PORT" instruction. The POST instruction tells - the remote server to connect to our specified IP address. The - string may be a plain IP address, a hostname, a network - interface name (under UNIX), or just a plain '-' to use the - systems default IP address. + <parameter>CURLOPT_FTPPORT</parameter>: Passez une chaîne de + caractères qui désignera l'adresse IP utilisée + pour l'instruction FTP "PORT". L'instruction POST indique au serveur + distant de se connecter cette adresse IP. La chaîne peut + être une adresse IP, un nom d'hôte, un nom d'interface + réseau (sous UNIX), ou juste '-', pour utiliser les IP par + défaut du système. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_COOKIE</parameter>: Pass a string - containing the content of the cookie to be set in the HTTP - header. + <parameter>CURLOPT_COOKIE</parameter>: Passez une chaîne de + caractères qui contiendra le contenu du cookie, à + transmettre dans l'entête HTTP. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_SSLCERT</parameter>: Pass a string - containing the filename of PEM formatted certificate. + <parameter>CURLOPT_SSLCERT</parameter>: Passez une chaîne de + caractères qui contiendra le nom de fichier du certificat, + au format PEM. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_SSLCERTPASSWD</parameter>: Pass a string - containing the password required to use the CURLOPT_SSLCERT - certificate. + <parameter>CURLOPT_SSLCERTPASSWD</parameter>: Passez une chaîne + de caractères qui contient le mot de passe nécessaire + pour utiliser le certificat CURLOPT_SSLCERT. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_COOKIEFILE</parameter>: Pass a string - containing the name of the file containing the cookiee data. - The cookie file can be in Netscape format, or just plain - HTTP-style headers dumped into a file. + <parameter>CURLOPT_COOKIEFILE</parameter>: Passez une chaîne de + caractères qui contiendra le nom du fichier contenant les + données de cookie. Le fichier de cookie peut être au + format Netscape, ou simplement des entêtes HTTP écrites + dans un fichier. </simpara> </listitem> <listitem> <para> - <parameter>CURLOPT_CUSTOMREQUEST</parameter>: Pass a string to - be used instead of GET or HEAD when doing an HTTP request. - This is useful for doing DELETE or another, more obscure, HTTP - request. + <parameter>CURLOPT_CUSTOMREQUEST</parameter>: Passez une chaîne + de caractères qui sera utilisé à la place de GET + ou HEAD lors des requêtes HTTP. Cette commande est pratique pour + effectuer un DELETE, ou une autre commande HTTP exotique. <note> <simpara> - Don't do this without making sure your server supports the - command first. + N'utilisez pas cette commande sans vous assurer que le serveur l'accepte. </simpara> </note> </para> @@ -421,111 +410,107 @@ </itemizedlist> </para> <para> - The following options expect a file descriptor that is obtained - by using the <function>fopen</function> function: + Les options suivantes requièrent un pointeur de fichier, qui est + obtenu avec la fonction <function>fopen</function> : <itemizedlist> <listitem> <simpara> - <parameter>CURLOPT_FILE</parameter>: The file where the output - of your transfer should be placed, the default is STDOUT. + <parameter>CURLOPT_FILE</parameter>: Le fichier de sortie de votre transfert. + Par défaut, STDOUT. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_INFILE</parameter>: The file where the - input of your transfer comes from. + <parameter>CURLOPT_INFILE</parameter>: Le fichier d'entrée de + votre transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_WRITEHEADER</parameter>: The file to write - the header part of the output into. + <parameter>CURLOPT_WRITEHEADER</parameter>: Le fichier de destination + de l'entête de la sortie du transfert. </simpara> </listitem> <listitem> <simpara> - <parameter>CURLOPT_STDERR</parameter>: The file to write - errors to instead of stderr. + <parameter>CURLOPT_STDERR</parameter>: Le fichier d'erreurs. </simpara> </listitem> </itemizedlist> </para> </refsect1> </refentry> - <refentry id="function.curl-exec"> <refnamediv> <refname>curl_exec</refname> - <refpurpose>Perform a CURL session</refpurpose> + <refpurpose>Excécute une session CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>bool + <funcdef>bool <function>curl_exec</function> </funcdef> - <paramdef>int + <paramdef>int <parameter>ch</parameter> </paramdef> </funcprototype> </funcsynopsis> <para> - This function is should be called after you initialize a CURL - session and all the options for the session are set. Its purpose - is simply to execute the predefined CURL session (given by the - <parameter>ch</parameter>). + Cette fonction doit être appelée après + l'initialisation et le paramètrage d'une session CURL. + Son but est simplement d'éxécuter la session + <parameter>ch</parameter>. </para> </refsect1> </refentry> - <refentry id="function.curl-close"> <refnamediv> <refname>curl_close</refname> - <refpurpose>Close a CURL session</refpurpose> + <refpurpose>Ferme une session CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>void + <funcdef>void <function>curl_close</function> </funcdef> - <paramdef>int + <paramdef>int <parameter>ch</parameter> </paramdef> </funcprototype> </funcsynopsis> <para> - This functions closes a CURL session and frees all ressources. - The CURL handle, <parameter>ch</parameter>, is also deleted. + Cette fonction ferme une session CURL et libère + toutes les ressources reservées. L'identifiant CURL, + <parameter>ch</parameter>, est aussi effacé. </para> </refsect1> </refentry> - <refentry id="function.curl-version"> <refnamediv> <refname>curl_version</refname> - <refpurpose>Return the current CURL version</refpurpose> + <refpurpose>Retourne la version courante de CURL</refpurpose> </refnamediv> <refsect1> <title>Description</title> <funcsynopsis> <funcprototype> - <funcdef>string + <funcdef>string <function>curl_version</function> </funcdef> <void/> </funcprototype> </funcsynopsis> <para> - The <function>curl_version</function> function returns a string - containing the current CURL version. + <function>curl_version</function> retourne une chaîne + avec la version courante de la librairie CURL. </para> </refsect1> </refentry> </reference> - <!-- Keep this comment at the end of the file Local variables: mode: sgml