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

Conditions for block-content within layout-builder

Hi,

I migrated my side from Drupal 7 to drupal 10. In drupal 7 I used panels with  blocks. And build 2 blocks with condition urls' to show the block.

Now in drupal 10 I have a layout for the vocabulary
If I want to show different content in a block by a term, is this possible somehow? Or do I need to add all blocks with condition url's to the lay-out? And then because of the condition in the block, it shows itself like in Drupal 7?

How do I replace hook_field_widget_WIDGET_TYPE_form_alter() ?

Hi everyone. I am trying to create dependency fields in paragraphs. In Drupal 9.2 i can use hook_field_widget_WIDGET_TYPE_form_alter() but in Drupal > 9.2 i am having some problems....

When i use this hook: hook_field_widget_single_element_WIDGET_TYPE_form_alter that in theory replace hook_field_widget_WIDGET_TYPE_form_alter() i can't access to fields in $element['subform']....

Someone had the same problem ?

subform key looks like

Changing the way childs of the first page of a book are showing

Hi.
I'd like the child pages of the first page of a book not showing themself under that first page.

For example, on this page, I don't want the child page being under that first page because I already have a block showing them on the left.

I think I've just something to "cut" in some twig templates but I can manage to find where or what.

A little help would be appreciate.

Best regards.

D

Which folders are 'really required' at run time in production?

When I ran 'tree' command on newly installed drupal 10 code. I see

5426 directories, 19085 files

Are all these folders really required at run time on production site?

Is it possible to omit some folders from production release ... in order to reduce number of files in the hosting account?

Please let me know.

Thanks

Views css token's doesn't work

Drupal 10.1.6 version, trying to use token's in view custom css, but nothing working.

I added term id field to list, excluded from display, and on Title field: Style settings -> Custom field HTML -> Add HTML class -> added class [Term:id] (tried different variations) and it shows like - <span class="field-content -termid">. I need it to be <span class="field-content 3">.

Or maybe it's other way to do this?

Drupal once with dynamically added elements [solvend + solution]

This is again driving me mad half of the day. Since the new once plugin, things got harder.

I have dynamically generated elemsnts in a list i want to delete. Simple add/delete.

Everything works find but i have a problem on deleting the new added. The following code works fine but is fired MULTIPLE times. But as it seems once can not be used with document or window.

Pages

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