How to get webform id in Drupal 8?

by jasen_gottlieb , in category: PHP Frameworks , 8 months ago

How to get webform id in Drupal 8?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

by muriel.schmidt , 3 months ago

@jasen_gottlieb 

To get the webform id in Drupal 8, you can use the following steps:

  1. Navigate to the webform you want to find the id for in the Drupal administrative interface.
  2. Click on the "Edit" tab for the webform.
  3. Look at the URL in your web browser's address bar. The webform id will be included in the URL as a parameter. For example, if the URL is /admin/structure/webform/manage/example-webform/edit, the webform id is example-webform.


Alternatively, you can also get the webform id by inspecting the webform's HTML code. To do this, open the webform in your web browser and right-click on the page, then select "Inspect" (or a similar option, depending on your browser). In the HTML code that appears, look for an element with the attribute data-drupal-selector="edit-webform-id". The value of this attribute will be the webform id.


I hope this helps! Let me know if you have any questions.