how to avoid timeouts with remote API requests?

I’m developing a plugin, WP SoundSystem, that makes WordPress rest requests to my remote API api.spiff-radio.org. That API is scraping content on the web. Which means that it might be slow to get the data. So WP SoundSystem plugin requests data on api.spiff-radio.org… …api.spiff-radio.org scrapes the web… …api.spiff-radio.org returns a response… …WP SoundSystem plugin gets…

Force SSL using FORCE_SSL_ADMIN

I followed this advice from the official docs to force SSL: define(‘FORCE_SSL_ADMIN’, true); if (strpos($_SERVER[‘HTTP_X_FORWARDED_PROTO’], ‘https’) !== false) $_SERVER[‘HTTPS’]=’on’; WordPress runs in a docker container. When it starts it says WARNING: The _SERVER variable is not set. Defaulting to a blank string. And WordPress’ logs show this: PHP Fatal error: Assignments can only happen to…

Error while updateing to Drupal 8.8.0

Updated Drupal from 8.7.8 to 8.8.0 with: composer update –with-dependencies That part went well, but when I run: drush updb I get following error: In ProcessBase.php line 188: Unable to decode output into JSON: Syntax error Error: Call to a member function getConfigDependencyKey() on null in Drupal\taxonomy\Plugin\views\filter\TaxonomyIndexTid- >calculateDependencies() (line 394 of /var/www/html/drupal/web/core/modules/taxonomy/src/Plugin/views/filter/TaxonomyIndex Tid.php). Checked the…

Lost name attribute after recharge select field with ajax callback

I have a great trouble with ajax callback, I need to recharge a select field, the callback goes right, but, the returned field in ajax request goes without name attribute, so, I lost it while submit is resolved. Code: //method buildForm $result = \Drupal\my_module\Controller\Contaminante::list(); //database logic foreach ($result as $it){ $arrSelectContaminantes[$it[“id_contaminante”]] = t($it[“descripcion”]); } $form[‘select_contaminantes’]…