Hoping someone can help, this is making me crazy. For the life of me I cannot get a Drupal 9 site to send PHP Mail, but a Drupal 7 site on basically the same setup does without fail. The only real difference is Drupal 9 is using PHP 8.1.6 and the Drupal 7 site is using PHP 7.3.27. Web Server
Tag: drupal
Drupal Error 502 bad gateway. When I Access TabPages inside of Content
I’m having this issue with Drupal after an update from Drupal 7 to Drupal 8. The error is the following, when I go to the admin page, I go to content -> filter by -> tab pages -> and try to access a tab page a 502 bad gateway error presents. My question is, someone has encounter with this particular
Turning a CSV into a nested JSON object in PHP, Drupal 8
I’m trying to turn a CSV into a JSON object made of nested arrays for each row within the file. I’ve tried a handful of similar SO questions but haven’t found quite the right solution. I’m attempting to set up a JSON object with a handful of nested objects, based on the first value in each row of the CSV.
PHP with Kafka – rdkafka
Iam dealing with kafka and php, Im beginner the kafka has been set upped correctly on the server, now am on local I have installed: librdkafka.dll on xamp/php and php_rdkafka.dll on xamp/php/ext and i added this on php.ini: extension=php_rdkafka.dll then, i have created a php page contains this code: Answer Are you trying to connect to confluent cloud? I would
How to fix Illegal offset type in Drupal/mystore/vendor/composer/composer/src/Composer/DependencyResolver/Pool.php:61
I’m very new to Drupal and trying to install it with composer. My composer install went well, but now, each time I try to do something, I get this error in the console : I get the feeling that this may be a compatibility issue ? Here is my composer.json : I have absolutely no idea how to fix this,
How to access to node fields in drupal 8
I’m having some issues, I’m loading some nodes and i want to get some values field, this is how is my field I’m loading my nodes like this: But i dont know how to get en fr and pt fields values Could you please help me? Regards Mario Answer You can load translation for each language then get corresponding field’s
Sum up the array values
I am working on a custom module in drupal and need to sum up the [value], However I tried different approaches using array_column, array_sum, but didn’t get the solution. Any help would be appreciated. Thanks. Code Answer You could make use of array_map here instead of an accumulator: Edit, as a full example:
Error: Undefined class constant ‘MYSQL_ATTR_USE_BUFFERED_QUERY’
Currently I’m getting this kind of message and I don’t know how to fix it. The command php -m tells me that PDO and pdo_mysql are there. I’m using Drupal-8 with php7.1.20 on Ubuntu 18.04.1 LTS [Tue Sep 04 09:27:48.210064 2018] [php7:notice] [pid 2183] [client 10.56.99.1:53758] Error: Undefined class constant ‘MYSQL_ATTR_USE_BUFFERED_QUERY’ in /var/www/dev/web/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php on line 134 #0 /var/www/dev/web/core/lib/Drupal/Core/Database/Database.php(376): DrupalCoreDatabaseDrivermysqlConnection::open(Array)n#1 /var/www/dev/web/core/lib/Drupal/Core/Database/Database.php(166):
Invalid Run Id After running drupal page using XHProf
I have installed the Drupal XHProf 7.x-1.0-beta2 module and enabled it on the Modules page of my site. I have turned enabled the use of the module at Configuration -> Development -> XHProf settings (/admin/config/development/xhprof) by checking ON ” Enable profiling of all page views and drush requests. ” Now what? When I visit a page and click “XHProf output”
Apache Solr search autocomplete
I’m using apache solr search engine to implement my site search. I able to setup the Apache Solr Search module and now my search is working as I need. Now I trying to implement an search autocomplete …