Auto Terms Of Service And Privacy Policy Shortcodes

Below, you’ll find a detailed guide on how to add the Auto Terms Of Service And Privacy Policy Shortcodes to your WordPress website, including their parameters, examples, and PHP function code. Additionally, we’ll assist you with common issues that might cause the Auto Terms Of Service And Privacy Policy Plugin shortcodes not to show or not to work correctly.

Before starting, here is an overview of the Auto Terms Of Service And Privacy Policy Plugin and the shortcodes it provides:

Plugin Icon
WP AutoTerms: Privacy Policy Generator (GDPR & CCPA), Terms & Conditions Generator, Cookie Notice Banner

"WP AutoTerms: Privacy Policy Generator (GDPR & CCPA), Terms & Conditions Generator, Cookie Notice Banner is a comprehensive solution for creating legal notices, terms of service, privacy policies, and cookie banners in compliance with GDPR & CCPA regulations."

★★★★☆ (234) Active Installs: 100000+ Tested with: 6.1.4 PHP Version: 5.3
Included Shortcodes:
  • [my_terms_of_service]
  • [my_privacy_policy]
  • [handle_shortcode]

Auto Terms Of Service And Privacy Policy [my_terms_of_service] Shortcode

The ‘my_terms_of_service’ shortcode is a feature of the Auto Terms of Service and Privacy Policy plugin. It generates a terms of service section on your website. This shortcode checks if terms should be displayed. If not, it shows a ‘coming soon’ message. When terms are available, it prints them using a template.

Shortcode: [my_terms_of_service]

Examples and Usage

Basic example – Displays the default terms of service on your website.

[my_terms_of_service /]

PHP Function Code

In case you have difficulties debugging what causing issues with [my_terms_of_service] shortcode, check below the related PHP functions code.

Shortcode line:

add_shortcode( 'my_terms_of_service', array( __CLASS__, 'my_terms_of_service' ) );

Shortcode PHP function:

function my_terms_of_service() {
		$ret = static::_prologue( 'my_terms_of_service' );
		if ( ! static::_should_show() ) {
			return $ret . static::_coming_soon( __( 'Terms are coming soon.', WPAUTOTERMS_SLUG ) );
		}

		return $ret . \wpautoterms\print_template( 'legacy/terms-of-service', static::_get_vars(), true );
	}

Code file location:

auto-terms-of-service-and-privacy-policy/auto-terms-of-service-and-privacy-policy/includes/legacy-shortcodes.php

Auto Terms Of Service And Privacy Policy [my_privacy_policy] Shortcode

The Auto Terms of Service and Privacy Policy plugin shortcode is used to generate a privacy policy. It checks if a policy should be displayed, if not, it shows a ‘coming soon’ message.

Shortcode: [my_privacy_policy]

Examples and Usage

Basic Example – A simple usage of the ‘my_privacy_policy’ shortcode which displays the privacy policy. If the policy is not available, it will display a ‘coming soon’ message.

[my_privacy_policy /]

PHP Function Code

In case you have difficulties debugging what causing issues with [my_privacy_policy] shortcode, check below the related PHP functions code.

Shortcode line:

add_shortcode( 'my_privacy_policy', array( __CLASS__, 'my_privacy_policy' ) );

Shortcode PHP function:

function my_privacy_policy() {
		$ret = static::_prologue( 'my_privacy_policy' );
		if ( ! static::_should_show() ) {
			return $ret . static::_coming_soon( __( 'Privacy Policy is coming soon.', WPAUTOTERMS_SLUG ) );
		}

		return $ret . \wpautoterms\print_template( 'legacy/privacy-policy', static::_get_vars(), true );
	}

Code file location:

auto-terms-of-service-and-privacy-policy/auto-terms-of-service-and-privacy-policy/includes/legacy-shortcodes.php

Conclusion

Now that you’ve learned how to embed the Auto Terms Of Service And Privacy Policy Plugin shortcodes, understood the parameters, and seen code examples, it’s easy to use and debug any issue that might cause it to ‘not work’. If you still have difficulties with it, don’t hesitate to leave a comment below.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *