Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $url_send_grid = config_load('url_send_grid');
- $params = array(
- 'api_user' => config_load('send_grid_user'),
- 'api_key' => config_load('send_grid_key'),
- 'to' => $to,
- 'subject' => $subject,
- 'from' => $from,
- 'html' => $message,
- );
- $params['text'] = strip_tags($params['html']);
- $res = run_api($url_send_grid, $params);
- if (isset($res['message']) && $res['message'] == 'success') {
- echo 'ok';
- }else{
- echo'not ok';
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement