gpsa_document_settings

  1. Description
  2. Usage
  3. Parameters
  4. Examples
    1. Modify the content loading message.
    2. Enable for all documents of type `post`
  5. Since

Description

Filter the document level settings.

Usage

Applied globally

add_filter( 'gpsa_document_settings', 'my_custom_function' );

Applied to specific form

add_filter( 'gpsa_document_settings_FORMID', 'my_custom_function' );

Parameters

$post_id int

The ID of the post.

Examples

Modify the content loading message.

add_filter( 'gpsa_document_settings', function( $settings, $post_id ) {
   $settings['gpsa_content_loading_message'] = 'Loading content...';
    return $settings;
}, 10, 2 );

Enable for all documents of type `post`

This example shows hoe to enabled GP Submit to Access for all posts and requires the form with ID 1 to be submitted.

Could not fetch snippet.

Since

  • 1.0.5 Hook added.