const prefixer = require('gulp-autoprefixer');
const rename = require('gulp-rename');
const rigger = require('gulp-rigger');
const sass = require('gulp-sass');
const uglify = require('gulp-uglify');
const sourcemaps = require('gulp-sourcemaps');
const terser = require('gulp-terser');
const nodesass = require('node-sass');
const imagemin = require('gulp-imagemin');
const del = require('delete');
const watch= require('watch');
const browserSync = require('browser-sync').create();
const { series, parallel, src, dest, gulp } = require('gulp');
// Собираем html
const startHtml = () => {
return src('src/*.html')
.pipe(rigger())
.pipe(dest('build'))
.pipe(browserSync.stream());
};
// Изменение файлов
const watcher = () => {
browserSync.init({
server: {
baseDir: './src/'
},
notify: false
});
watch('src/**/*.html', startHtml);
}
//exports.default(series(startHtml, watcher)); - не работает, говорит: exports.default is not a function
exports.default = (series(startHtml, watcher));
<form action="mail.php" method="POST" class="form contacts-form">
<?php
$name = $_POST['name'];
$email = $_POST['email'];
$phone = $_POST['phone'];
$message = $_POST['message'];
$name = htmlspecialchars($name);
$email = htmlspecialchars($email);
$phone = htmlspecialchars($phone);
$message = htmlspecialchars($message);
$name = urldecode($name);
$email = urldecode($email);
$phone = urldecode($phone);
$message = urldecode($message);
$name = trim($name);
$email = trim($email);
$phone = trim($phone);
$message = trim($message);
if (mail("SVOYU_POCHTU@mail.ru", "Заявка с сайта", "Телефон: ".$phone." Сообщение: ".$message. "ФИО:".$name.". E-mail: ".$email ." . From: SVOYU_POCHTU@mail.ru \r\n"))
{ echo "сообщение успешно отправлено";
} else {
echo "при отправке сообщения возникли ошибки";
}?>
<?php
$name= '';
$phone = '';
$email= '';
$message ='';
if (isset($_POST['service'])) {$service = trim($_POST['service']);}
if (isset($_POST['phone'])) {$phone = trim($_POST['phone']);}
if (isset($_POST['textarea'])) {$user_message = trim($_POST['textarea']);}
$address = 'xxxxxx@mail.ru';
$mes = "Тема: Заявка с сайта!\r\nИмя: $name\r\nТелефон: $phone\r\nE-mail: $email\r\nСообщение: $message";
$sub='Заявка с сайта';
$send = mail ($address,$sub,$mes,"Content-type:text/plain; charset = utf-8\r\nFrom:$email");
ini_set('short_open_tag', 'On');
header('Refresh: 3; URL=index.html');
echo 'OK';
Выведет: 12345678910