Email notifications for student and teacher creation are redirecting to localhost:8000 instead of your production Vercel URL.
Updated both notification files to use config('app.url') instead of hardcoded URLs:
app/Notifications/TeacherPasswordNotification.phpapp/Notifications/StudentPasswordNotification.php
Your app is deployed at a URL like:
https://abs.vercel.appORhttps://abs-[your-project-name].vercel.app
To find it:
- Go to https://vercel.com/dashboard
- Click on your
absproject - Copy the production URL shown at the top
Method A: Via Vercel Dashboard (Recommended)
- Go to your project in Vercel Dashboard
- Click Settings → Environment Variables
- Add a new variable:
- Key:
APP_URL - Value:
https://your-actual-vercel-url.vercel.app(replace with your actual URL) - Environment: Select "Production"
- Key:
- Click Save
- Go to Deployments tab and click Redeploy on the latest deployment
Method B: Via Command Line (if you have Vercel CLI)
cd /home/yoadyo/VScode/laravel/abs
vercel env add APP_URL production
# When prompted, enter your production URL: https://your-url.vercel.app
vercel --prodUpdate line 5 in your .env file:
APP_URL=https://your-actual-vercel-url.vercel.appAfter redeploying, when you create a new teacher or student:
- The email will be sent
- The "Login to Your Account" button will redirect to your production Vercel URL
- No more localhost redirects!
If your Vercel URL is https://abs-yoadyo8120.vercel.app, set:
APP_URL=https://abs-yoadyo8120.vercel.app
The email login button will then link to:
https://abs-yoadyo8120.vercel.app/login