Still on Drupal 7? Security support for Drupal 7 ended on 5 January 2025. Please visit our Drupal 7 End of Life resources page to review all of your options.
First of all sorry for my english, my native language is spanish.
Ok, does anyone know if it's possible to set by default the option "new book" into the dropdown of the "index book" of the book module? But just if you want to create a new book, not if you want to add a child page for an existed book
I have user created content. I use the content-moderation plugin, so a user can update his nodes but the update will only be published after moderation from an editor. I like to display a little batch (has new unpublished version) for the user on his nodes, to give him an information about the moderation state.
I know, I can get a moderation state via $node->moderation_state->value; in preprocess_node_function. But this value ignores the last unmoderated revision and says always "published",
Drupal 8 allows you to duplicate a webform from the admin interface, which is great, but is there a way to do this programmatically? I can't seem to find any posts regarding this on the forums. I suspect there's a function to do this hidden somewhere.