PHP code example of pittica / post-sendgrid

1. Go to this page and download the library: Download pittica/post-sendgrid 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/ */

    

pittica / post-sendgrid example snippets

 php


return [
    'fields' => [
        'whitelisted' => [
            'message'
        ],
        'email' => 'email',
        'subject' => 'subject',
        'name' => 'name',
        'labels' => [
            'message' => 'Message',
            'email' => 'E-Mail',
            'subject' => 'Subject'
        ]
    ],
    'sender' => [
        'address' => '[email protected]',
        'name' => 'YOUR NAME'
    ],
	'api' => [
		'key' => 'SendGrid API KEY'
	],
    'recaptcha' => [
        'key' => 'RECAPTCHA KEY',
        'field' => 'g-recaptcha'
    ]
];