{{-- EMAIL TEMPLATE --}}
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="{{ $current_language }}" xmlns="http://www.w3.org/1999/xhtml">
- <head>
+<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>CCV Formulaire</title>
<style type="text/css">
- body {
- font-family: Arial, sans-serif;
- }
- table {
- border-style: solid;
- border-color: #aaa;
- border-width: 1px 1px 0 1px;
- }
- td {
- padding: 12px 18px 12px 12px;
- border-bottom: 1px solid #aaa;
- }
+ body {
+ font-family: Arial, sans-serif;
+ }
+ table {
+ border-style: solid;
+ border-color: #aaa;
+ border-width: 1px 1px 0 1px;
+ }
+ td {
+ padding: 12px 18px 12px 12px;
+ border-bottom: 1px solid #aaa;
+ }
</style>
- </head>
- <body>
+</head>
+<body>
- <h1 style="font-size: 24px; margin-bottom: 1.5em;">{{ $subject }}</h1>
+<h1 style="font-size: 24px; margin-bottom: 1.5em;">{{ $subject }}</h1>
- <table cellpadding="0" cellspacing="0" border="0">
- @foreach($data as $label => $value)
- <tr @if($loop->even) bgcolor="#eeeeee" @endif>
- <td valign="top" align="right"><strong>{{ rtrim($label, ':') }}</strong></td>
- <td>
- @if (is_array($value))
- <ul style="margin: 0; padding-left: 1em;">
- <li>{!! implode('</li><li>', $value) !!}</li>
- </ul>
- @else
- {!! nl2br($value) !!}
- @endif
- </td>
+<table cellpadding="0" cellspacing="0" border="0">
+ @php($bg = "#fff")
+ @foreach($data as $label => $value)
+ @if(in_array(strtolower($label), ['years','months']))
+ @php($label = 'How long have you been suffering? '.$label)
+ @endif
+
+ @if(strtolower($label) === 'size')
+ @php($label = $label. ' cm')
+ @endif
+
+ @if(strtolower($label) === 'weight')
+ @php($label = $label. ' kg')
+ @endif
+
+ @if(in_array($label, ['tingling-numbness-date','strength-loss-date']))
+ @php($label = 'Since when?')
+ @endif
+
+ <tr bgcolor="{{$bg}}">
+ <td valign="top" align="right"><strong>{!! rtrim($label, ':') !!}</strong></td>
+ <td>
+ @if (is_array($value))
+ <ul style="margin: 0; padding-left: 1em;">
+ <li>{!! implode('</li><li>', $value) !!}</li>
+ </ul>
+ @else
+ {!! nl2br($value) !!}
+ @endif
+ </td>
</tr>
- @endforeach
- </table>
- </body>
-</html>
+ @endforeach
+</table>
+</body>
+</html>
\ No newline at end of file