[DOC-CVS] [doc-en] master: Update curl-escape.xml (#4948)
[email protected] (Mikhail Alferov via GitHub)
| Newsgroups | php.doc.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: Mikhail Alferov (mmalferov)
Committer: GitHub (web-flow)
Pusher: TimWolla
Date: 2025-10-24T23:16:21+02:00
Commit: https://github.com/php/doc-en/commit/98ee565bfbea26d2a9c8f8a8707f0403603f719e
Raw diff: https://github.com/php/doc-en/commit/98ee565bfbea26d2a9c8f8a8707f0403603f719e.diff
Update curl-escape.xml (#4948)
The `curl_close()` call has been removed — the fix was there, just not the comment :)
Changed paths:
M reference/curl/functions/curl-escape.xml
Diff:
diff --git a/reference/curl/functions/curl-escape.xml b/reference/curl/functions/curl-escape.xml
index 3ee6d7ef2459..4e9bddab28ad 100644
--- a/reference/curl/functions/curl-escape.xml
+++ b/reference/curl/functions/curl-escape.xml
@@ -66,6 +66,7 @@
<programlisting role="php">
<![CDATA[
<?php
+
// Create a curl handle
$ch = curl_init();
@@ -77,10 +78,11 @@ $location = curl_escape($ch, 'Hofbräuhaus / München');
$url = "http://example.com/add_location.php?location={$location}";
// Result: http://example.com/add_location.php?location=Hofbr%C3%A4uhaus%20%2F%20M%C3%BCnchen
-// Send HTTP request and close the handle
+// Set options and send HTTP request
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_exec($ch);
+
?>
]]>
</programlisting>