• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

php code to send checkbox form results to email

phpemail


PHP Snippet 1:

$servicetype = implode(",", $_POST['servicetype']);
$mail->body .= $servicetype."\r\n";

PHP Snippet 2:

$servicetype = $_POST['servicetype'];
if(isset($servicetype)) {
    $mail->body .= "servicetype: \r\n";

    foreach ($servicetype as $selected) {
        $mail->body .= " > ".$selected."\r\n";      
    }
}

Related Snippets

Why is this PHP array not the same?

Laravel insert dynamic input values with radio button

Adding Multiple Custom Post Types in Wordpress

browsersync doesn't work with XAMPP

how to identify the web server name of remote host

how to use extended ASCII instead of unicode in PHP

How to solve cURL error 60: SSL certificate in Laravel 5 while Facebook authentication

How to get result of the formula on import xlsx with maatwebsite using Laravel? I get formula and not value of the formula

Doctrine ORM: Excluding Records Based on Values of Nested Relationships

using random function but it's displaying duplicates

Fatal error: Uncaught TypeError: count(): Argument #1 ($var) must be of type Countable|array, null given in

How to break out of a foreach once a condition is met?

Unable to Edit config.inc.php

Laravel Get Days In Month From Month Number?

How to get page number on dompdf PDF when using "view"

About Contact Privacy policy Terms and conditions