Discussion Components#
You can add inline discussion components to any container in your course.
Create the XML File for a Discussion Component#
There are two ways to create an inline discussion component in your course. The preferred way is to include a discussion tag inside a vertical, as demonstrated in the following example.
<vertical display_name="Lesson_1_Unit_1">
...
<discussion
display_name="Peer Grading"
discussion_category="Essays"
discussion_target="Peer Grading"
discussion_id="unique_id_here"
/>
</vertical>
The second way, which is deprecated, is to create an XML file in the
discussion
directory for each inline discussion component in your course,
and to then reference XML file in a discussion tag inside a vertical, as shown
in the following example.
The following is inside a vertical:
<vertical display_name="Lesson_1_Unit_1">
<discussion
url_name="Peer_Grading"
/>
</vertical>
Create the file discussion/Peer_Grading.xml
to define the inline discussion
component, containing the following code.
<discussion
display_name="Peer Grading"
discussion_category="Essays"
discussion_target="Peer Grading"
discussion_id="unique_id_here"
/>
Note that the name of the XML file must match the value of the @url_name
attribute of the discussion
element in the vertical XML file.
Discussion Component XML File Elements#
The root element of the XML file for the discussion component file is
discussion
.
The discussion
element contains no children.
discussion
Element Attributes#
Attribute |
Meaning |
---|---|
Required. |
The name of the category for the inline discussion as shown in the main
Discussion tab of the course. For example: |
Required. |
The name of the subcategory for the inline discussion as shown in the
Discussion tab of the course. For example: |
|
Optional. The value that is displayed to students as the name of the
discussion component. If you do not supply a |
Optional. |
The unique identifier that the discussion forum service uses to refer to this inline discussion component. This value must be unique across all courses in an Open edX deployment. We recommend that you leave this value blank so that a unique identifier is automatically generated. |
Obsolete. |
Use |
Obsolete. |
Use |
Example Discussion Component XML File#
The following example shows an XML file for a discussion component.
<discussion
discussion_category="Essays"
discussion_target="Peer Grading"
display_name="Peer Grading"
/>