<code lang="php">
<?php
if ($_SERVER["REQUEST_METHOD"] == "POST") {
if (isset($_POST['site'])) {$site = '<b>Сайт:</b> '.$_POST['site'];}
if (isset($_POST['geo'])) {$geo = '<b>Геграфия рекламы:</b> '.$_POST['geo'];}
if (isset($_POST['phone'])) {$phone = '<b>Телефон:</b> '.$_POST['phone'];}
if (isset($_POST['email'])) {$email = '<b>email:</b> '.$_POST['email'];}
if (isset($_POST['formData'])) {$formData = $_POST['formData'];}
$to = "mail@gmail.com";
$sendfrom = "mail@gmail.com";
$headers = "From: " . strip_tags($sendfrom) . "\r\n";
$headers .= "Reply-To: ". strip_tags($sendfrom) . "\r\n";
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html;charset=utf-8 \r\n";
$subject = "$formData";
$message = "$formData
$site
$geo
$email
$phone";
$send = mail ($to, $subject, $message, $headers);
if ($send == 'true')
{
echo '<center>
Спасибо за отправку вашего сообщения!
</center>';
}
else
{
echo '<center>
<b>Ошибка. Сообщение не отправлено!</b>
</center>';
}
} else {
http_response_code(403);
echo "Попробуйте еще раз";
}?>
</code>
<script defer src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script defer type="application/javascript" src="js/libs.min.js"></script>
<script defer type="application/javascript" src="js/js.js"></script>
function PrintElem(elem)
{
Popup($(elem).html());
}
function Popup(data)
{
var mywindow = window.open('', 'table', 'height=1000,width=1000');
mywindow.document.write('<html><head>');
mywindow.document.write('<link rel="stylesheet" type="text/css" media="print" href="/project/print.css">');
mywindow.document.write('</head><body ><table>');
mywindow.document.write(data);
mywindow.document.write('</table></body></html>');
mywindow.document.print;
mywindow.document.close();
mywindow.focus();
mywindow.addEventListener('load', function(){
mywindow.print();
mywindow.close();
}, false);
}
div.innerHTML = "<input name=\"name[]" + curFieldNameId + "\" type=\"text\" id=\"date\" /> <a onclick=\"return deleteField(this)\" href=\"#\">[x]</a>";
div.innerHTML = "<input name=\"name[]" + curFieldNameId + "\" type=\"text\" id=\"date" + curFieldNameId + "\" /> <a onclick=\"return deleteField(this)\" href=\"#\">[x]</a>";
document.getElementById("parentId").appendChild(div);
$("#date"+curFieldNameId ).mask("99-99-9999");
<?php
$a = array('0defsdfsdf', 10.5, 5.4, 3.3, 2.2, 0.1);
echo min($a);
Так вот. Если оно приводится к нулю, то чего оно не в результате? Если 0.1 больше 0
SELECT COUNT(*)
FROM joiners_tourdate, joiners_artist
JOIN joiners_country on joiners_tourdate.country_id = joiners_country.id
WHERE joiners_tourdate.artist_id = joiners_artist.id
AND joiners_tourdate.country_id = 3
SELECT COUNT(*)
FROM joiners_tourdate
JOIN joiners_country on joiners_tourdate.country_id = joiners_country.id
JOIN joiners_artist ON joiners_tourdate.artist_id = joiners_artist.id
WHERE joiners_tourdate.country_id = 3
date('Y-m-d h:i', $model->published_at);
1486924655 - 2017-02-12 06:37:35
2017-02-12 06:37:00
1486881420
date('Y-m-d h:i:s', $model->published_at);