validate([ 'title' => 'required|string|max:255', 'description' => 'nullable|string', 'name' => 'required|string|max:255', 'address' => 'nullable|string', 'phone' => 'nullable|string|max:20', 'email' => 'nullable|email|max:255', 'whatsapp' => 'nullable|string|max:20', ]); ContactInfo::updateOrCreate( ['id' => 1], $request->all() ); return redirect()->back()->with('success', 'Informasi kontak berhasil diperbarui'); } public function show() { $contactInfo = ContactInfo::where('is_active', true)->first(); return view('contact.hubungikami', compact('contactInfo')); } }