PHP code example of nimos / wp-nonce-wrapper

1. Go to this page and download the library: Download nimos/wp-nonce-wrapper 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/ */

    

nimos / wp-nonce-wrapper example snippets


$nonce = WpNonceWrapper::create_nonce();

$url = WpNonceWrapper::nonce_url( 'http://example.com' );

WpNonceWrapper::nonce_field();

$valid = WpNonceWrapper::verify_nonce( $nonce );

WpNonceWrapper::nonce_ays( $someAction );