Re: [users@httpd] php curl

2017-02-24 Thread Roman Gelfand
This is fixed.  I had to disable selinux on the web server.

On Fri, Feb 24, 2017 at 8:38 AM Roman Gelfand  wrote:

> correction... I am getting Curl error: Failed to connect to : Permission
> denied
>
>
> On Fri, Feb 24, 2017 at 5:30 AM Roman Gelfand  wrote:
>
> How do you configure Apache to execute scripts?
>
> In the least, it looks like curl get request doesn't get executed.
>
> On Fri, Feb 24, 2017, 3:11 AM Marat Khalili  wrote:
>
> > it appears that get request never gets executed
>
> You didn't write what happens. Does your PHP code gets executed at all?
> One common error is not configuring Apache to recognize scripts in the
> first place.
>
> --
>
> With Best Regards,
> Marat Khalili
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
> For additional commands, e-mail: users-h...@httpd.apache.org
>
> --
> Thanks,
> R. Gelfand
>
> --
> Thanks,
> R. Gelfand
>
-- 
Thanks,
R. Gelfand


Re: [users@httpd] php curl

2017-02-24 Thread Roman Gelfand
correction... I am getting Curl error: Failed to connect to : Permission
denied


On Fri, Feb 24, 2017 at 5:30 AM Roman Gelfand  wrote:

> How do you configure Apache to execute scripts?
>
> In the least, it looks like curl get request doesn't get executed.
>
> On Fri, Feb 24, 2017, 3:11 AM Marat Khalili  wrote:
>
> > it appears that get request never gets executed
>
> You didn't write what happens. Does your PHP code gets executed at all?
> One common error is not configuring Apache to recognize scripts in the
> first place.
>
> --
>
> With Best Regards,
> Marat Khalili
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
> For additional commands, e-mail: users-h...@httpd.apache.org
>
> --
> Thanks,
> R. Gelfand
>
-- 
Thanks,
R. Gelfand


Re: [users@httpd] php curl

2017-02-24 Thread Roman Gelfand
How do you configure Apache to execute scripts?

In the least, it looks like curl get request doesn't get executed.

On Fri, Feb 24, 2017, 3:11 AM Marat Khalili  wrote:

> it appears that get request never gets executed

You didn't write what happens. Does your PHP code gets executed at all?
One common error is not configuring Apache to recognize scripts in the
first place.

--

With Best Regards,
Marat Khalili


-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org

-- 
Thanks,
R. Gelfand


Re: [users@httpd] php curl

2017-02-24 Thread Marat Khalili

it appears that get request never gets executed


You didn't write what happens. Does your PHP code gets executed at all? 
One common error is not configuring Apache to recognize scripts in the 
first place.


--

With Best Regards,
Marat Khalili


-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



[users@httpd] php curl

2017-02-23 Thread Roman Gelfand
I am executing successfully the following code using php line mode and it
returns a stream.  However, when running the same code as part of web page,
it appears that get request never gets executed.  Why?  any help is
appreciated.

$apikey = '73f1ad78334ea3e8dedfb8f568d8537f';
$username='auser';
$dealid=1;
$apiurl='http://apserveri02:8080/rest/default/qadm/v1/';


$ch = curl_init();

$headr = array();
$headr[] = 'Accept: application/json';
$headr[] = 'Content-Type: application/json';
$headr[] = 'Authorization '.$apikey.':1';

curl_setopt($ch, CURLOPT_HTTPHEADER,$headr);

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_URL,
$apiurl."Rsnapshot?filter=dealid=$dealid");
$content = curl_exec($ch);
echo $content;
exit;

-- 
Thanks,
R. Gelfand