Webhost firewall blocking paypal ipn ssl? - php

Error log:
[07-Mar-2016 23:26:23 Europe/Moscow] PHP Warning: fsockopen(): php_network_getaddresses: getaddrinfo failed: Name or service not known in /home/domeofli/public_html/test/payments.php on line 81
[07-Mar-2016 23:26:23 Europe/Moscow] PHP Warning: fsockopen(): unable to connect to ssl://www.paypal.com:443 (php_network_getaddresses: getaddrinfo failed: Name or service not known) in /home/domeofli/public_html/test/payments.php on line 81
[07-Mar-2016 23:30:40 Europe/Moscow] PHP Warning: fsockopen(): php_network_getaddresses: getaddrinfo failed: Name or service not known in /home/domeofli/public_html/test/payments.php on line 81
[07-Mar-2016 23:30:40 Europe/Moscow] PHP Warning: fsockopen(): unable to connect to ssl://www.paypal.com:443 (php_network_getaddresses: getaddrinfo failed: Name or service not known) in /home/domeofli/public_html/test/payments.php on line 81
Line 81:
$fp = fsockopen ('ssl://www.paypal.com', 443, $errno, $errstr, 30);
So, what do you think? Could it be my dodgy web host (it's very dodgy, i'm just here for the low price of $5 a year lol), i tested out my script about 5-10 times and only once did my information get sent into the database (5 minutes later).
thanks.

OpenSSL library has to be installed to open ssl:// URL. Check it with a phpinfo() call.

Related

Is there any way to check .PEM file is Valid or not in iOS?

I have created production AdHoc .pem files. I have followed this steps:
By using This Link
I created .PEM file and i checked does this valid or not by using following command like:
$php simplepush.php
but i am getting an error like::
Warning: stream_socket_client(): php_network_getaddresses: getaddrinfo failed: nodename nor servname provided, or not known in /Users/mac-jarc/Desktop/SimplePush/simplepush.php on line 21
Warning: stream_socket_client(): unable to connect to ssl://gateway.sandbox.push.apple.com:2195 (php_network_getaddresses: getaddrinfo failed: nodename nor servname provided, or not known) in /Users/mac-jarc/Desktop/SimplePush/simplepush.php on line 21
Failed to connect: 0 php_network_getaddresses: getaddrinfo failed: nodename nor servname provided, or not known
But in my PHP developer said it's a .PEM file mistake . I tought it's not(Because i am very sure my .PEM file is perfect) and i suggested to him like it's a server ports issue
Can you please help me out regarding this:: How would i check does my .PEM file is valid or not.
Here is my php code:

PHP stream_socket_client() Warning

I am building a new WordPress site for a client and all of a sudden today I am seeing this error at the top of the screen. I have never seen this before. Any ideas what could be causing this to happen now? Also how to fix it?
Warning: stream_socket_client(): php_network_getaddresses: getaddrinfo failed: Name or service not known in /var/www/wp-includes/class-http.php on line 787
Warning: stream_socket_client(): unable to connect to tcp://www.MY-DOMAIN.com:80 (php_network_getaddresses: getaddrinfo failed: Name or service not known) in /var/www/wp-includes/class-http.php on line 787
Not sure if you are using a VM but when I had this error I resolved it by adding an entry to my hosts file in my vagrant machine that pointed back to localhost.
127.0.0.1 www.MY-DOMAIN.com

PHP file_get_contents not working

i am having a problem with PHP file_get_contents.
$html = file_get_html($csfd_link);
Writes an error:
Warning: file_get_contents() [function.file-get-contents]:
php_network_getaddresses: getaddrinfo failed: Name or service not
known in /home/vo003500/www_root/admin/simple_html_dom.php on line 76
Warning: file_get_contents(http://www.example.com/)
[function.file-get-contents]: failed to open stream:
php_network_getaddresses: getaddrinfo failed: Name or service not
known in /home/vo003500/www_root/admin/simple_html_dom.php on line 76
I do not know what it is. The server is allow_url_fopen ON
Thanks
Edit:
Until now it worked, but the last 2 weeks not working...
It looks like your suffering from DNS (Domain Name Service) resolution error. Make sure there is a proper DNS server entry in /etc/resolv.conf.

Connection to my sql data base

First, let me note that the connection infomation is not the correct info. I made a database on 1and1 and I want to connect to it from the web. I am not getting the syntax correct here, can someone point me in the right direction?
Here is what I have:
//connect to DB
$dbc=mysql_connect('http://db232154114.db.1and1.com','db232154114','password');
mysql_select_db('tableName',$dbc)
Here are the errors that I am getting:
Warning: mysql_connect() [function.mysql-connect]: php_network_getaddresses:
getaddrinfo failed: No such host is known. in
C:\xampp\htdocs\ciss225Testing\homework\final_process.php on line 35
Warning: mysql_connect() [function.mysql-connect]: [2002] php_network_getaddresses:
getaddrinfo failed: No such host is kn (trying to connect via tcp://http:3306) in
C:\xampp\htdocs\ciss225Testing\homework\final_process.php on line 35
Warning: mysql_connect() [function.mysql-connect]: php_network_getaddresses:
getaddrinfo failed: No such host is known. in
C:\xampp\htdocs\ciss225Testing\homework\final_process.php on line 35
Warning: mysql_select_db() expects parameter 2 to be resource, boolean given in
C:\xampp\htdocs\ciss225Testing\homework\final_process.php on line 37
Try to replace http://db232154114.db.1and1.com/ with IP address of SQL server you're connecting to
Remove http:// and enable remote MySQL connections from your server's cPanel or so
your connection string is not right. get rid of the "http://" stuff; that is not part of the db server's hostname.

Php, socket and connecting to pop3-server

I'm trying to connect to the pop3-server with php. Here is my code:
$pop3Server = 'mail.roller.ru';
$pop_conn = fsockopen($pop3Server, 110, $errno, $errstr, 10);
print fgets($pop_conn, 1024);
Warning: fsockopen() [function.fsockopen]: php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution in /home/ockonal/public_html/mail_parser.php on line 45
Warning: fsockopen() [function.fsockopen]: unable to connect to mail.roller.ru:110 (php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution) in /home/ockonal/public_html/mail_parser.php on line 45
Warning: fgets() expects parameter 1 to be resource, boolean given in /home/ockonal/public_html/mail_parser.php on line 46
What's wrong? I'm sure in pop3-server address. It doesn't print anything.
Temporary failure in name resolution
Isn't it clear enough?
if your server having troubles with name resolving, you can use 62.113.86.215 IP address instead.

Categories