SMTP
SMTP
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Title</title>
</head>
<body>
<table
border="1"
cellpadding="0"
cellspacing="0"
width="100%"
style="border-collapse: collapse; background-color:#F8FAFB;"
>
<tr>
<td>
<table border="1" cellpadding="0" cellspacing="0" width="600" style="margin: 0 auto;">
<tr>
<td height="40px"></td>
</tr>
<tr>
<td>{{.Something}}</td>
</tr>
<tr>
<td>{{.Something}}</td>
</tr>
<tr>
<td>{{.Something}}</td>
</tr>
<tr>
<td height="40px"></td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
경고
- 이미지가 필요한 경우 svg 등을 직접 삽입하지 말고
https가 적용된 경로에 이미지를 업로드하고 그 경로를 사용합니다 - 최대한
<table>,<tr>,<td>태그를 사용하여 레이아웃을 구성합니다 <style>가 지원되지 않을 수 있습니다, 인라인 스타일을 사용하는 것이 좋습니다- https://validator.w3.org/#validate_by_input+with_options 에서 검사합니다
이메일 템플릿을 작성할 때는 border="1"로 설정하여 원하는 레이아웃을 먼저 구성합니다. 작업을 마친 후 border="0"으로 설정하여 테두리를 제거합니다.
<table>border="<0|1>"width="<px|%>"
<tr><td>align="<left|right|center|justify|char>valign="<top|middle|bottom|baseline>"
정보
사용했던 버튼 예시입니다.
<table
border="0"
cellpadding="0"
cellspacing="0"
align="center"
style="
border-collapse: collapse;
border-radius: 6px;
background: #228be6;
"
>
<tr>
<td align="center">
<a
href="https://wiki.loliot.net"
style="
color: #ffffff;
text-align: center;
font-family: Arial, Helvetica, sans-serif;
font-size: 16px;
font-style: normal;
font-weight: 500;
width: 200px;
line-height: 48px;
display: inline-block;
text-decoration: none;
-webkit-text-size-adjust: none;
"
>Button</a
>
</td>
</tr>
</table>