|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #53080 Error when request on port 3306
Submitted: 2010-10-15 23:45 UTC Modified: 2010-10-16 09:47 UTC
From: kevinpleiter at gmail dot com Assigned:
Status: Not a bug Package: cURL related
PHP Version: Irrelevant OS: Windows XP
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: kevinpleiter at gmail dot com
New email:
PHP Version: OS:


 [2010-10-15 23:45 UTC] kevinpleiter at gmail dot com
When I get a request from a host which is using mysql, I'll get an error I can't turn off ("R (strange chars) Host 'XXXXX' is not allowed to connect to this MySQL server"). I can't suppress this error.

Test script:
$host = ''; // for example

$ch = curl_init();
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_NOBODY, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 5);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, false);
curl_setopt($ch, CURLOPT_URL, $host);
curl_setopt($ch, CURLOPT_PORT, 3306);
$test = curl_exec($ch);
            $page .= 'JA - 3306<br />';
            $page .= 'Nee - 3306<br />';
echo $page;

Expected result:
Getting JA - 3306 or NEE 3306


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2010-10-16 09:47 UTC]
-Status: Open +Status: Bogus
 [2010-10-16 09:47 UTC]
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

curl_setopt($ch, CURLOPT_RETURNTRANSFER, false);

should be

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

otherwise the response is printed.
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Tue Apr 13 14:01:23 2021 UTC