Module 1

Published: 4 Jun 2021 | Last updated 4 June 2021
1. Create a module in Drupal 8 with name: Node JSON Data, machine name node_json_data.2. Create a configuration form in which an API key is accepted from the user. API Key will be a maximum 16 digit text value.3. Create a controller with route /data/{apikey}/{node-id}, where api key should be same as API key saved in settings, and node-id should be valid node id existing in the system.4. Once the route is accessed and everything is right, return JSON data on the node.5. Push all the code on Github.

  • techtud official
  • @techtud
  • Senior editor at techtud

Recent Blog Posts

1. Create a module in D8 website which provides node JSON data through an endpoint.2. Alter the basic website settings form

1. Create a form with following 4 fields : Number of Nodes (Integer), Content Type (Dropdown of all content type in website), Title and Body. As soon

1. Create a practice module named: Node Generator (node_generator).2. Create a form with class "NodeGeneratorForm" and route