test this shit
This commit is contained in:
parent
b065f03559
commit
2d1c606fdf
|
|
@ -29,18 +29,21 @@ class ContactController extends Controller
|
|||
|
||||
$resp = $recaptcha->verify($recapresponse, $_SERVER['REMOTE_ADDR']);
|
||||
if($resp->isSuccess()) {
|
||||
if($request->file('file')){
|
||||
$image = $request->file('file');
|
||||
$path = $request->file('file')->store(
|
||||
'uploads/mails/'.time().'.'.$image->getClientOriginalExtension()
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
$image = $request->file('file');
|
||||
$path = $request->file('file')->store(
|
||||
'uploads/mails/'.time().'.'.$image->getClientOriginalExtension()
|
||||
);
|
||||
|
||||
$data = array(
|
||||
'name' => $request->name,
|
||||
'email' => $request->email,
|
||||
'subject' => $request->subject,
|
||||
'message' => $request->message,
|
||||
'image' => $path
|
||||
'image' => $path ?? ''
|
||||
);
|
||||
// Mail::send('email_temp', [
|
||||
// 'data' => $data
|
||||
|
|
|
|||
|
|
@ -5,5 +5,7 @@
|
|||
<p style="margin-top: 0px;padding-left: 25px;">{{ $data['subject'] }}</p>
|
||||
<p style="font-weight: bold;margin-bottom: 0px;padding-left: 25px;">Ugradylan Hat: </p>
|
||||
<p style="margin-top: 0px;padding-left: 25px;">{{ $data['message'] }}</p>
|
||||
<img src="https://turkmentv.gov.tm/{{ $data['image'] }}" alt="Turkmentv">
|
||||
@if($image)
|
||||
<a href="https://turkmentv.gov.tm/{{ $data['image'] }}" target="_blank" alt="Turkmentv">
|
||||
@endif
|
||||
<p style="background-color: aliceblue;padding: 25px;padding-top: 10px;padding-bottom: 10px;font-weight: bold;color: #024198;">Turkmen Tv Contact Form Page</p>
|
||||
|
|
|
|||
Loading…
Reference in New Issue