How do you pass an arg to a script on an ssl server?

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
zeek
Forum Commoner
Posts: 48
Joined: Mon Feb 27, 2006 7:41 pm

How do you pass an arg to a script on an ssl server?

Post by zeek »

What is the proper way to pass the foo argument from a script on Server A to a script on Server B.

Server A is not running SSL
Server B is running SSL

If I'm going about this all wrong please don't assume that I have a good reason :) My script is running on server A. It needs to pass an argument to a script on Server B. The following two attempts have given confusing results:

Attempt1:

Code: Select all

include('https://securedomaincom/script.php?foo=bar');
This resulted in my browser trying to download the script. Very strange.

Attempt2:

Code: Select all

$result = file('https://securedomaincom/script.php?foo=bar');
This resulted in the following error...

ERROR 2: file(): SSL operation failed with code 1. OpenSSL Error messages: error:24064064:random number generator:SSLEAY_RAND_BYTES:PRNG...


What is the proper way to pass the foo argument to a script on Server B? Thanks in advance.
User avatar
bokehman
Forum Regular
Posts: 509
Joined: Wed May 11, 2005 2:33 am
Location: Alicante (Spain)

Post by bokehman »

Attempt 1 is correct. If its trying to download the file this means php is not installed or not working properly on that server.
Post Reply