Node

Last updated on
30 April 2025

Features

  • Create / Modify / Delete Content Types
  • Create / Modify Nodes
  • Delete Nodes

Available Tags

  • content_type
  • node

Automatic extraction of patterns files status

Yes, supported in versions >= 7.x-2.x

Examples

Content_type tag, create a Content Type

# Pattern
# YAML Content Pattern
# QScience

info:
  title: Content Type (create)
  description: Creates a Content Type
  author: QScience
  category: Content
  version: 1.0
  core: 7.x
  author_website: qlectives.eu

actions:

  - create:
     tag: content_type
     name: Test Content Type
     type: test_content_type # machine readable name
     description: Test Content Type Long Description
     title_label: Title of Test Content Type
     node_preview: 1
     help: help text
     node_options:
      - status
      - promote
      - sticky

Content_type tag, modify a Content Type

# YAML Content Pattern
# QScience

info:
  title: Content Type (modify)
  description: Modifies a Content Type
  author: QScience
  category: Content
  version: 1.0
  core: 7.x
  author_website: qlectives.eu

actions:

  - modify:
     tag: content_type
     name: Test Content Type2
     type: test_content_type # machine readable name
     description: Test Content Type Long Description2
     title_label: Title of Test Content Type2
     node_preview: 2
     help: help text2
     node_options:
      - promote
      - sticky
      - revision

Content_type tag, delete a Content Type

# YAML Content Pattern
# QScience

info:
  title: Content Type (delete)
  description: Deletes a Content Type
  author: QScience
  category: Content
  version: 1.0
  core: 7.x
  author_website: qlectives.eu

actions:

  - delete:
     tag: content_type
     name: Test Content Type
     type: test_content_type # machine readable name

Node tag, delete a Node

# YAML Content Pattern
# QScience

info:
  title: Node (delete)
  description: Deletes a Node by ID
  author: QScience
  category: Content
  version: 1.0
  core: 7.x
  author_website: qlectives.eu

actions:

  - delete:
     tag: node
     nid: 1
     type: article

Node tag, create a Node (not yet working)

info: 
  title: Example Article creation
  description: Creates an example article node
  author: QSCience
  version: 1.0
  category: Content
  core: 7.x
  author_website: qlectives.eu

actions:
  - create:
      tag: node
      type: article
      title: Test Article
      body: lorem ipsum ...

Help improve this page

Page status: Not set

You can: