I have a part of code in my componenent which works in Joomla! 3.9.x, but in Joomla! 4.0-beta-dev i get a 503 error. My code is the following :

use Joomla\Http\Http;
use Joomla\Http\Transport\Stream as StreamTransport;

public function sendtostopforumspam()
 $options = array();

 $transport = new StreamTransport($options);

 $http = new Http($options, $transport);

 $data = array('username' => $username, 'ip_addr' => $ip, 'email' => $email, 'api_key' => $key);

 $response = $http->post('https://www.stopforumspam.com/add', $data);

 if ($response->code == '200')
  // do something...

In the response i can see an error 503

What are changes in Joomla! 4.0 which prevent that working ?

Thanks by advance

  • The 503 comes from your site or stopforumspam? stopforumspam gets utterly bombarded by requests, so there is a likelihood that your issue is actually someone else's issue. Please clarify where the error is coming from. Can you pull up a copy of your 3.9 environment and see if you are successful from there? These basic diagnostics help volunteers to understand the scenario.
    – mickmackusa
    Nov 12 '19 at 8:24
  • The error 503 from stopforumspam, i have re-tested it and the issue was that i tried to add to stopforumspam database a local ip. I have tried with a public ip and it has worked. Nov 13 '19 at 12:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.