bbp_get_form_topic_content()

Return the value of topic content field

Description

Return

(string) Value of topic content field

Source

File: bp-forums/topics/template.php

	function bbp_get_form_topic_content() {

		// Get _POST data
		if ( bbp_is_post_request() && isset( $_POST['bbp_topic_content'] ) ) {
			$topic_content = stripslashes( $_POST['bbp_topic_content'] );

		// Get edit data
		} elseif ( bbp_is_topic_edit() ) {
			$topic_content = bbp_get_global_post_field( 'post_content', 'raw' );

		// No data
		} else {
			$topic_content = '';
		}

		return apply_filters( 'bbp_get_form_topic_content', $topic_content );
	}

Changelog

Changelog
Version Description
bbPress (r2976) Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.