Answer the question
In order to leave comments, you need to log in
Text not being sent from select?
There is such a form
<form action="" id="calculate-form">
<div class="app-flex">
<div class="app-flex__item">
<div class="app-title">
Выберите материал из списка
</div>
<div class="select">
<select v-model="selected" name="?">
<option v-for="option in options" :value="option.value" name="?">
{{ option.text }}
</option>
</select>
</div>
<div class="value-wrapper">
<div class="value-ton">Объем в тоннах <div>{{totalTon}}</div>
</div>
<div class="value-sum">Итого <div>{{total}} руб.</div>
</div>
</div>
<input type="hidden" :value="total" name="total">
<input type="hidden" :value="totalTon" name="totalton">
</div>
<div class="app-flex__item">
<div class="app-title">
Укажите нужный объем в м3
<input type="number" name="valuem3" id="" v-model="number">
</div>
<div class="app-title">
Укажите адрес доставки
<input type="text" placeholder="Введите адрес доставки" name="adress">
</div>
<div class="app-title">
Укажите телефон для связи
<input type="text" placeholder="+7-999-999-99-99" name="phone">
</div>
</div>
</div>
<div class="button">
<button>Отправить</button>
</div>
</form>
<?php
$recepient = "[email protected]";
$siteName = "Ajax-форма";
$phone = trim($_POST["phone"]);
$option = trim($_POST["option"]);
$total = trim($_POST["total"]);
$totalton = trim($_POST["totalton"]);
$valuem3 = trim($_POST["valuem3"]);
$adress = trim($_POST["adress"]);
//$title = trim($_POST["order"]);
$message = "Телефон: $phone \nОпция: $option \nСтоимость: $total \nВтоннах: $totalton \nВм3: $valuem3 \nАдрес: $adress";
$pagetitle = "Заявка с сайта \"$siteName\"";
mail($recepient, $pagetitle, $message, "Content-type: text/plain; charset=\"utf-8\"\n From: $recepient");
?>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question