I am getting an error in laravel 5.2 on the telegram view with an undefined variable posts. I am using AdminLTE templates and here is my code so far:
on my Controller:
public function storeMessage(Request $request)
{
$request->validate([
'email' => 'required|email',
'message' => 'required'
]);
$text = "[HEADLINE] Informasi Portal Beasiswa\n"
. "<b>Email Address: </b>\n"
. "$request->email\n"
. "<b>Message: </b>\n"
. $request->message;
Telegram::sendMessage([
'chat_id' => env('TELEGRAM_CHANNEL_ID', ''),
'parse_mode' => 'HTML',
'text' => $text
]);
return redirect('beasiswa');
}
and my error like bellow: enter image description here
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire