Using Drupal 9.x and I am trying to get the content from a view where the display is a page and the path is /people/%. The '%' is a reference to a taxonomy term. How do I get the content in this case?
In my company many departments have their own forms (PDFs, Words) and many other documents. Each department uploads their documents on their own sections but no one can follow up the updated files and may be another version is uploaded somewhere else. is there a module that can mange this? I want to centralize the documents and make them available only in one place and if a version is updated there will be a text that says last update is on... etc.
Hi, I'm interested in sorting the query result on an entityReference field (field_ufficio).
I have done various tests but I have not succeeded.
The code is this
I am trying to create a custom module to createa new node programatically. I believe this short and sweet code snippet will do it.
$node = \Drupal::entityTypeManager()->getStorage('node')->create([
'type' => 'page',
'title' => 'This is the Title',
'body' => 'Some text in the body.',
]);
$node->save();
\Drupal::messenger()->addStatus(t('The page has been created.'));
But where in my custom module do I place this code? Should it be a Plugin, a Controller, a Service, or what?
I need to insure a user didn't modify a url in their browser to access information he or she is not supposed to have access to. The url paths I'm monitoring is /users/123. "/users/123" is the path to a view with a contextual filter. I want to prevent the user from changing 123 to something else and viewing and editing another user's information. 123 is an id that is in a custom field in their user profile set by an administrator.