Hi, i am trying to run a php script by using following code
Dim j As HttpJob
j.Initialize("", Me)
'j.PostString("http://saeedhassan.atwebpages.com/r.php", query)
j.Download("http://saeedhassan.atwebpages.com/r.php")
Wait For (j) jobdone (j As HttpJob)
If j.Success Then
Log(j.GetString)
End If
I am getting following error whenever i run it
ResponseError. Reason: java.net.UnknownServiceException: CLEARTEXT communication to saeedhassan.atwebpages.com not permitted by network security policy, Response:
i have a paid basic plan and i have checked with the site team, they say that the outgoing http request is allowed.
Also when i run this script on a web browser by pasting http://saeedhassan.atwebpages.com/r.php in the browser , it runs and returns the json string.
I am using following php code
<?php
$conn = new mysqli("pdb48.awardspace.net", "3373050_pivot", "K8888882058@", "3373050_pivot");
if ($conn->connect_error) {
die("ERROR: Unable to connect: " . $conn->connect_error);
}
echo 'Connected to the database.<br>';
$result = $conn->query("SELECT * FROM menuitems");
//echo "Number of rows: $result->num_rows";
if ($result->num_rows > 0) {
// output data of each row
$rows = array();
while($r = $result->fetch_assoc()) {
$rows[] = $r;
}
} else {
echo "0 results";
}
$res = json_encode($rows);
echo $res;
$result->close();
$conn->close();
?>
can anyone please help me out in this.
Dim j As HttpJob
j.Initialize("", Me)
'j.PostString("http://saeedhassan.atwebpages.com/r.php", query)
j.Download("http://saeedhassan.atwebpages.com/r.php")
Wait For (j) jobdone (j As HttpJob)
If j.Success Then
Log(j.GetString)
End If
I am getting following error whenever i run it
ResponseError. Reason: java.net.UnknownServiceException: CLEARTEXT communication to saeedhassan.atwebpages.com not permitted by network security policy, Response:
i have a paid basic plan and i have checked with the site team, they say that the outgoing http request is allowed.
Also when i run this script on a web browser by pasting http://saeedhassan.atwebpages.com/r.php in the browser , it runs and returns the json string.
I am using following php code
<?php
$conn = new mysqli("pdb48.awardspace.net", "3373050_pivot", "K8888882058@", "3373050_pivot");
if ($conn->connect_error) {
die("ERROR: Unable to connect: " . $conn->connect_error);
}
echo 'Connected to the database.<br>';
$result = $conn->query("SELECT * FROM menuitems");
//echo "Number of rows: $result->num_rows";
if ($result->num_rows > 0) {
// output data of each row
$rows = array();
while($r = $result->fetch_assoc()) {
$rows[] = $r;
}
} else {
echo "0 results";
}
$res = json_encode($rows);
echo $res;
$result->close();
$conn->close();
?>
can anyone please help me out in this.