rcp_messages_settings

Note: This is part of the developer docs and is considered custom code.
Unfortunately, we cannot provide support for custom code at this time as we do not have the additional resources that would be necessary to provide support for custom code.

If you need assistance with this, please reach out to our list of consultants for further assistance:
https://codeable.io/developers/restrict-content-pro/

Used to add additional options below the message settings in  Restrict > Settings > General (below "Premium Content Message").

Parameters:

  • $rcp_options - Array of Restrict Content Pro settings.

Example:

function ag_rcp_messages_settings( $rcp_options ) {
	?>
	<tr valign="top">
		<th>
			<label for="rcp_settings[your_custom_setting]"><?php _e( 'Your Custom Setting' ); ?></label>
		</th>
		<td>
			<input type="text" id="rcp_settings[your_custom_setting]" class="regular-text" name="rcp_settings[your_custom_setting]" value="<?php echo isset( $rcp_options['your_custom_setting'] ) ? esc_attr( $rcp_options['your_custom_setting'] ) : ''; ?>">
			<p class="description"><?php _e( 'Your description goes here.' ); ?></p>
		</td>
	</tr>
	<?php
}

add_action( 'rcp_messages_settings', 'ag_rcp_messages_settings' );
Have more questions? Submit a request
Powered by Zendesk