This forum is for module development and code related questions, not general module support. For general support, use the Post installation forum.

notice : ResponseAttachmentsProcessor->processHtmlHead() on each page

Hello

I'm coming from Drupal 8.7, through 8.9 and I'm now in 9.3

Since D 8.7 I'm repeatedly getting this error whose I like to get rid of. I see it on every page request and it pollutes very much my watchdog. It doesn't seem harming anything though.

I've not the beginning of a clue and  couldn't find anything  that can help on Google.
If someone knows how to solve it or how at least remove this error from filling up my watchdog...

How to get user's token for firebase messaging

Hi,

I need to send push notification when a content is added to a group.
I just install firebase module,
I see how to send a push message, but I can't see how to get the user's token.

states in form_alter

I am using the states on a field of a content type but I get this error

js file loaded in form where js file not listed in library

I have the following in my mymodule.libraries.yml:

user:
  version: 1.12
  js:
    js/set-office-name.js: {}
    js/password.js: {}
  css:
    component:
      css/bnc-user.css: { minified: false }

contact_log:
  version: 1.12
  js:
    js/set-office-name.js: {}
    js/enable-district-office.js: {}
  css:
    component:
      css/bnc-user.css: { minified: false }

In my module.modules I have two hook_form_alter functions where I set the libraries used:

1) mymodule_form_node_bnc_message_form_alter:

How to programmatically append fields to node object when cloning with createDuplicate()

I’m trying to setup a custom module which clones the content from NODETYPE_A to NODETYPE_B. For most part, both nodetypes use the same fields, but NODETYPE_B has a few additional ones. For example:

NODETYPE_A:
- Title (title)
- Body (body)
- Date (field_date_agenda)

NODETYPE_B:
- Title (title)
- Body (body)
- Date (field_date_agenda)
- Number of items (field_int_how_many)
- Reference to NodeTypeA (field_noderef_nta)

Tips and Tricks for Drupal development ?

In older php days, when I got stuck developing code, I would just output some things to the screen.

That's isn't possible anymore with all the layers.

How do you look into objects?

Do you write things to a text file or are there other tricks?

For example, I'm in the middle of some code and I want to look into $responsive_image_style->getKeyedImageStyleMappings();

How can I have a look at what's inside?

Pages

Subscribe with RSS Subscribe to RSS - Module development and code questions