PHP code example of mupic / wp-api-yoast-meta

1. Go to this page and download the library: Download mupic/wp-api-yoast-meta library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

mupic / wp-api-yoast-meta example snippets


//GET params will take precedence over constants
define('YOAST_REST_META', false); //false - Disable automatic meta seo input. (Equivalent in get request: meta=false)
define('YOAST_REST_OG', false); //false - Disable automatic open graph input. (Equivalent in get request: opengraph=false)
define('YOAST_REST_TW', false); //false - Disable automatic meta twitter input. (Equivalent in get request: twitter=false)
define('YOAST_REST_BC', false); //true - Return json breadcrumbs. "html" - Return html generated breadcrumbs. (Equivalent in get request: breadcrumbs=false)
define('YOAST_REST_SCHEMA', false); //false - Disable automatic microdata input. (Equivalent in get request: schema=false)

define('YOAST_REST_ENABLE_EMBED', false); //false - Disable yoast in fields called from _embed=true. (Equivalent in get request: yoast_embed=false)