intial-blog-setup #33
22
dist/api/index.php
vendored
22
dist/api/index.php
vendored
@ -346,12 +346,12 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
$headers1 .= "MIME-Version: 1.0\r\n";
|
||||
$headers1 .= "Content-Type: text/html; charset=UTF-8\r\n";
|
||||
|
||||
$message1 = "
|
||||
<html lang=\"en\">
|
||||
$message1 = <<<HEREA
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>{$data['subject']}</title>
|
||||
<style>
|
||||
@import url(\"https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap\");
|
||||
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap");
|
||||
body {
|
||||
font-family: Noto Sans KR, sans-serif;
|
||||
font-style: normal;
|
||||
@ -406,17 +406,17 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
<tr>
|
||||
<td>{$data['fName']}</td>
|
||||
<td>{$data['lName']}</td>
|
||||
<td><a href=\"mailto:{$data['email']}\">{$data['email']}</a></td>
|
||||
<td><a href="mailto:{$data['email']}">{$data['email']}</a></td>
|
||||
<td>{$data['subject']}</td>
|
||||
<td>{$data['message']}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
<hr>
|
||||
<p>Regards, <br> Rohit Pai <br> <a href=\"mailto:rohit@rohitpai.co.uk\">rohit@rohitpai.co.uk</a>
|
||||
<p>Regards, <br> Rohit Pai <br> <a href="mailto:rohit@rohitpai.co.uk">rohit@rohitpai.co.uk</a>
|
||||
</body>
|
||||
</html>
|
||||
";
|
||||
HEREA;
|
||||
|
||||
mail($data["email"], $data["subject"], $message1, $headers1);
|
||||
|
||||
@ -426,12 +426,12 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
$headers2 .= "MIME-Version: 1.0\r\n";
|
||||
$headers2 .= "Content-Type: text/html; charset=UTF-8\r\n";
|
||||
|
||||
$message2 = "
|
||||
<html lang=\"en\">
|
||||
$message2 = <<<HEREB
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>{$data['subject']}</title>
|
||||
<style>
|
||||
@import url(\"https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap\");
|
||||
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap");
|
||||
body {
|
||||
font-family: Noto Sans KR, sans-serif;
|
||||
font-style: normal;
|
||||
@ -484,14 +484,14 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
<tr>
|
||||
<td>{$data['fName']}</td>
|
||||
<td>{$data['lName']}</td>
|
||||
<td><a href=\"mailto:{$data['email']}\">{$data['email']}</a></td>
|
||||
<td><a href="mailto:{$data['email']}">{$data['email']}</a></td>
|
||||
<td>{$data['subject']}</td>
|
||||
<td>{$data['message']}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
";
|
||||
HEREB;
|
||||
|
||||
mail("rohit@rohitpai.co.uk", "{$data['fName']} {$data['lName']} filled in the form", $message2, $headers2);
|
||||
return $response->withStatus(201);
|
||||
|
@ -346,12 +346,12 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
$headers1 .= "MIME-Version: 1.0\r\n";
|
||||
$headers1 .= "Content-Type: text/html; charset=UTF-8\r\n";
|
||||
|
||||
$message1 = "
|
||||
<html lang=\"en\">
|
||||
$message1 = <<<HEREA
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>{$data['subject']}</title>
|
||||
<style>
|
||||
@import url(\"https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap\");
|
||||
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap");
|
||||
body {
|
||||
font-family: Noto Sans KR, sans-serif;
|
||||
font-style: normal;
|
||||
@ -406,17 +406,17 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
<tr>
|
||||
<td>{$data['fName']}</td>
|
||||
<td>{$data['lName']}</td>
|
||||
<td><a href=\"mailto:{$data['email']}\">{$data['email']}</a></td>
|
||||
<td><a href="mailto:{$data['email']}">{$data['email']}</a></td>
|
||||
<td>{$data['subject']}</td>
|
||||
<td>{$data['message']}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
<hr>
|
||||
<p>Regards, <br> Rohit Pai <br> <a href=\"mailto:rohit@rohitpai.co.uk\">rohit@rohitpai.co.uk</a>
|
||||
<p>Regards, <br> Rohit Pai <br> <a href="mailto:rohit@rohitpai.co.uk">rohit@rohitpai.co.uk</a>
|
||||
</body>
|
||||
</html>
|
||||
";
|
||||
HEREA;
|
||||
|
||||
mail($data["email"], $data["subject"], $message1, $headers1);
|
||||
|
||||
@ -426,12 +426,12 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
$headers2 .= "MIME-Version: 1.0\r\n";
|
||||
$headers2 .= "Content-Type: text/html; charset=UTF-8\r\n";
|
||||
|
||||
$message2 = "
|
||||
<html lang=\"en\">
|
||||
$message2 = <<<HEREB
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>{$data['subject']}</title>
|
||||
<style>
|
||||
@import url(\"https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap\");
|
||||
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Share+Tech+Mono&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;0,900;1,200;1,300;1,400;1,600;1,700;1,900&display=swap");
|
||||
body {
|
||||
font-family: Noto Sans KR, sans-serif;
|
||||
font-style: normal;
|
||||
@ -484,14 +484,14 @@ $app->post("/contact", function (Request $request, Response $response)
|
||||
<tr>
|
||||
<td>{$data['fName']}</td>
|
||||
<td>{$data['lName']}</td>
|
||||
<td><a href=\"mailto:{$data['email']}\">{$data['email']}</a></td>
|
||||
<td><a href="mailto:{$data['email']}">{$data['email']}</a></td>
|
||||
<td>{$data['subject']}</td>
|
||||
<td>{$data['message']}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
";
|
||||
HEREB;
|
||||
|
||||
mail("rohit@rohitpai.co.uk", "{$data['fName']} {$data['lName']} filled in the form", $message2, $headers2);
|
||||
return $response->withStatus(201);
|
||||
|
Loading…
Reference in New Issue
Block a user