new Date('0001-01-01 00:00:00');
// Date Mon Jan 01 0001 00:00:00 GMT+0230 (Москва, стандартное время)
new Date('0001-01-01 00:00:00Z');
// Date Mon Jan 01 0001 02:30:17 GMT+0230 (Москва, стандартное время)
$data = [[
"id" => 25,
"pid" => "0CjqYfx3NU1AghsPVoGFullXwl4umV",
"message" => "Одно лишь ё - это безумие!"
]];
echo json_encode($data, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT);
/*
[
{
"id": 25,
"pid": "0CjqYfx3NU1AghsPVoGFullXwl4umV",
"message": "Одно лишь ё - это безумие!"
}
]
*/
[
{
option_default_qty_t: "0",
option_name_t: "Пенсионер"
option_price_t: "200",
option_qty_t: "10",
option_qty_t_type: "inputbox",
option_rsv_t: "0",
option_sale_end_date: "2021-03-14",
option_sale_end_date_t: "2021-03-14 00:00",
option_sale_end_time: "00:00",
}, {
option_default_qty_t: "0",
option_name_t: "Ребёнок (до 8 лет)",
option_price_t: "700",
option_qty_t: "10",
option_qty_t_type: "inputbox",
option_rsv_t: "0",
option_sale_end_date: "2021-03-14",
option_sale_end_date_t: "2021-03-14 00:00",
option_sale_end_time: "00:00",
}, {
option_default_qty_t: "0",
option_name_t: "Обычный",
option_price_t: "1500",
option_qty_t: "10",
option_qty_t_type: "inputbox",
option_rsv_t: "0",
option_sale_end_date: "2021-03-14",
option_sale_end_date_t: "2021-03-14 00:00",
option_sale_end_time: "00:00",
}
]
$json = json_encode([
"api_key" => $api_key,
"message" => [
"global_substitutions" => [
"someVar" => "body.html"
],
"body" => [
"html" => $message
],
"subject" => $subject,
"from_email" => $from,
"from_name" => "NAME",
"reply_to" => $reply,
"track_links" => 1,
"track_read" => 1,
"recipients": [
["email" => $to]
]
]
]);