# ❓ FREQUENTLY ASKED QUESTIONS

**Answers to common questions about cPanel installation**

---

## INSTALLATION QUESTIONS

### Q1: Where do I get the project files?
**A:** You should have a folder called `Trust Tax Advisor` with all the files. This folder contains:
- `backend/` - Server code
- `frontend/` - Website code
- `database/schema.sql` - Database structure
- Documentation files

### Q2: How long does installation take?
**A:** 30-60 minutes total:
- Upload files: 5-10 minutes
- Database setup: 5 minutes
- Configuration: 5-10 minutes
- Node.js setup: 10-15 minutes
- Testing: 5 minutes

### Q3: Can a non-technical person do this?
**A:** Yes! Just follow the step-by-step guides carefully. No coding knowledge needed.

### Q4: What if I make a mistake?
**A:** Don't worry! Most things can be fixed:
- Wrong `.env` values? Just re-edit the file
- Import failed? Delete tables and import again
- App won't start? Click restart

---

## FILE UPLOAD QUESTIONS

### Q5: Why is FileZilla needed?
**A:** FileZilla is the easiest way to upload many files at once. Without it, you'd need to upload 100+ files individually via cPanel File Manager.

### Q6: My upload keeps failing - what do I do?
**A:** 
- Check your internet connection
- Disconnect and reconnect FileZilla
- Try uploading smaller chunks
- Check FTP credentials are correct
- Ask hosting provider to check FTP limits

### Q7: How do I know the upload is complete?
**A:** 
- FileZilla shows 0 files remaining
- Go to cPanel File Manager
- Navigate to public_html
- You should see `Trust Tax Advisor` folder with all contents

### Q8: Can I delete and re-upload if something goes wrong?
**A:** Yes! Just:
1. Right-click folder in FileZilla
2. Select "Delete"
3. Upload again from fresh

---

## DATABASE QUESTIONS

### Q9: What if I create the wrong database name?
**A:** 
- Go to cPanel → MySQL Databases
- Delete the wrong database
- Create a new one with correct name: `fmpdcrei_tta1`
- Import schema.sql again

### Q10: What's the database password?
**A:** You set it yourself during creation. For this guide, it's:
```
fmpdcrei_tta1
```
Keep it safe!

### Q11: How many tables should I have after import?
**A:** 12 tables:
1. users
2. connectors
3. clients
4. services
5. orders
6. leads
7. commissions
8. documents
9. form_templates
10. form_responses
11. otp_logs
12. audit_logs

### Q12: What does "ON DUPLICATE KEY UPDATE" mean?
**A:** It just means the default admin user will be created only once, even if schema.sql is imported multiple times.

### Q13: Can I modify the database?
**A:** Not recommended for beginners. If you need to:
- Add fields: Use cPanel → phpMyAdmin
- Delete records: Use cPanel → phpMyAdmin
- Contact developer for complex changes

---

## .ENV FILE QUESTIONS

### Q14: What is the .env file?
**A:** A secret file that stores sensitive information:
- Database password
- Email password
- WhatsApp API keys
- Secret codes

**NEVER share this file with anyone!**

### Q15: Where do I find .env?
**A:** It should be in: `backend/.env`
- It's a hidden file (starts with dot)
- Might not show up by default - check File Manager settings

### Q16: What if I delete .env by mistake?
**A:**
1. Copy `.env.example` again
2. Rename to `.env`
3. Fill in all values again
4. Save

### Q17: What does "CORS_ORIGIN" mean?
**A:** It tells the backend which websites can access it. Set it to your domain:
```
CORS_ORIGIN=https://yourdomain.com
```

### Q18: Why is JWT_SECRET important?
**A:** It's the code that signs your login tokens. Make it random and strong:
```
JWT_SECRET=aB3xYz9kLm2pQr5sT7uVwXyZ1aBcD4eF5gH6iJ7kL8mN9oP0qRsT
```

### Q19: Can I use my Gmail for SMTP?
**A:** For this guide, we use:
```
noreply@trusttaxadvisor.com
```

Yes, you CAN use Gmail, but requires "App Password" from Google.

---

## NODE.JS QUESTIONS

### Q20: What is Node.js?
**A:** It's the software that runs your backend server. cPanel manages it for you.

### Q21: Why do I need to click "NPM Install"?
**A:** It downloads all the code libraries your application needs (like database drivers, email libraries, etc.).

### Q22: How long does NPM Install take?
**A:** 5-15 minutes depending on internet speed. Be patient!

### Q23: What if NPM Install fails?
**A:**
1. Click Restart app
2. Wait 2 minutes
3. Try NPM Install again
4. If still fails, contact hosting provider

### Q24: Can I stop the Node.js app?
**A:** Yes, but then your website won't work. Only stop it for:
- Maintenance
- Updates
- Troubleshooting

### Q25: How do I restart the app?
**A:**
1. Go to Setup Node.js App
2. Find your app
3. Click Restart
4. Wait 1-2 minutes

---

## SSL/HTTPS QUESTIONS

### Q26: What is SSL?
**A:** It's the security certificate that makes your website HTTPS (encrypted).

### Q27: Is SSL required?
**A:** Yes! Modern websites need HTTPS. Use cPanel AutoSSL (it's FREE).

### Q28: How long does SSL take to activate?
**A:** Usually 1-5 minutes, sometimes up to 24 hours.

### Q29: Why does my browser say "Not Secure"?
**A:**
- SSL not installed yet - wait 5 minutes and refresh
- SSL certificate expired - use AutoSSL again
- Check in incognito window (clears browser cache)

### Q30: Can I use a different SSL certificate?
**A:** Yes, but AutoSSL is recommended. It's free and automatic.

---

## LOGIN & TESTING QUESTIONS

### Q31: What are the default admin credentials?
**A:**
- Mobile: `918733870977`
- Email: `admin@trusttaxadvisor.com`

### Q32: How do I receive the OTP?
**A:** It's sent via WhatsApp to `918733870977`. Make sure that WhatsApp account is active and has internet.

### Q33: What if I don't have access to that WhatsApp number?
**A:** Try email login instead:
1. Click "Login with Email"
2. Enter: `admin@trusttaxadvisor.com`
3. Wait for email with OTP
4. Enter OTP

### Q34: The API/health check shows an error, what does it mean?
**A:** Your backend has a problem. Check:
- Is database connected? (check `.env` credentials)
- Is Node.js app running? (click restart)
- Check error logs in cPanel

### Q35: Login page works but dashboard won't load?
**A:**
- Clear browser cache (Ctrl+Shift+Delete)
- Try private/incognito window
- Check internet connection
- Wait 1 minute and try again

---

## API & TECHNICAL QUESTIONS

### Q36: What is /api/health?
**A:** It's a test endpoint that checks if your backend is working. Should return:
```json
{"status": "ok", "timestamp": "2026-03-18T..."}
```

### Q37: What does "JSON" mean?
**A:** It's a format for showing data. Looks like:
```json
{
  "key": "value",
  "number": 123,
  "status": "ok"
}
```

### Q38: What does "CORS error" mean?
**A:** Frontend can't reach backend. Make sure:
- Backend URL is correct (usually yourdomain.com)
- CORS_ORIGIN in .env matches your domain
- Node.js app is running

### Q39: What is a port?
**A:** It's a communication channel. Different ports:
- 80: HTTP (old)
- 443: HTTPS (new)
- 3000: Development
- cPanel handles this automatically

### Q40: Can I change the port?
**A:** Not recommended. cPanel sets it automatically. Changing it requires advanced knowledge.

---

## TROUBLESHOOTING QUESTIONS

### Q41: Files uploaded but website doesn't load?
**A:**
1. Check if domain is pointing to public_html
2. Check if Node.js app is running
3. Check cPanel error logs
4. Wait 5 minutes for DNS to propagate

### Q42: Node.js app won't start?
**A:** Check in order:
1. Is startup file correct? (`backend/server.js`)
2. Is application root correct? (has full path)
3. Review `.env` file - are all fields correct?
4. Check error logs in cPanel

### Q43: Database connection fails?
**A:**
1. Go to MySQL Databases
2. Verify user exists: `fmpdcrei_tta1`
3. Verify user has ALL permissions
4. Verify database exists: `fmpdcrei_tta1`
5. Try resetting user password

### Q44: OTP not received?
**A:**
- Verify mobile number is correct: `918733870977`
- Check WhatsApp is active on that number
- Try email login instead
- Wait 3 minutes (API might be slow)
- Restart Node.js app

### Q45: Can't edit .env file?
**A:**
- Make sure file is named `.env` (not `.env.txt`)
- Right-click → Edit
- Edit might show permission error - ask hosting provider
- Try copying to `.env.temp`, editing, then renaming

---

## ACCOUNT & SECURITY QUESTIONS

### Q46: Is my data secure?
**A:** 
- Use HTTPS (always)
- Keep passwords safe
- Don't share `.env` file
- Regular backups

### Q47: Should I change the admin password?
**A:** Yes! After first login:
1. Go to admin settings
2. Change admin password
3. Change admin email to your email
4. Use a strong password

### Q48: What if I forget the admin password?
**A:** 
- You can't directly change it (no traditional password)
- The OTP system is the login method
- Make sure you have access to `918733870977` WhatsApp or `admin@trusttaxadvisor.com` email

### Q49: Can multiple people login?
**A:** Yes! Create additional users from admin panel:
- Client accounts
- Connector accounts
- Staff accounts
- Admin accounts
Each with their own credentials

### Q50: Is my email password secure?
**A:** Your email password is stored in `.env` on the server. It's:
- Encrypted by the server
- Not shown in browser
- Never sent to client
- Keep it safe!

---

## SUPPORT & HELP QUESTIONS

### Q51: Where is the detailed guide?
**A:** It's in: `CPANEL_INSTALLATION_GUIDE_NONDEVELOPER.md`
- Read step-by-step
- Follow each section
- Check the checklist

### Q52: Where is the visual guide?
**A:** It's in: `CPANEL_VISUAL_GUIDE.md`
- Shows where to click
- Shows what you should see
- Helps with navigation

### Q53: Where is the quick checklist?
**A:** It's in: `QUICK_INSTALLATION_CHECKLIST.md`
- Print it
- Check off each step
- Use as reference during installation

### Q54: Who should I contact if something breaks?
**A:** 
- **For cPanel issues**: Contact your hosting provider
- **For website issues**: Contact the developer
- **For database issues**: Contact your hosting provider
- **For custom features**: Contact the developer

### Q55: Can I install this myself if I'm not technical?
**A:** Absolutely! Just:
1. Read the guides carefully
2. Follow each step exactly
3. Take your time
4. Don't skip steps
5. If stuck, ask for help

---

## FINAL TIPS

### Pro Tip 1: Take Your Time
- Don't rush
- Read each instruction twice
- Make sure you understand before clicking

### Pro Tip 2: Save Screenshots
- Take screenshots after each step
- Screenshot errors if they happen
- Helpful for showing support if you need help

### Pro Tip 3: Keep Notes
- Write down what you did
- Note any errors
- Keep credentials in safe place

### Pro Tip 4: Double-Check URLs
- Wrong domain? Installation fails
- Check domain spelling: `yourdomain.com`
- Check it's HTTPS: `https://yourdomain.com`

### Pro Tip 5: Test Each Step
- After upload - verify files in File Manager
- After database - count 12 tables in phpMyAdmin
- After configuration - edit .env and verify
- After Node.js - wait and check error logs
- After SSL - try both http and https
- After restart - check /api/health endpoint
- After login - try admin panel

---

## STILL CONFUSED?

### Step 1: Read the Main Guide
📖 `CPANEL_INSTALLATION_GUIDE_NONDEVELOPER.md`
- Most thorough
- Explains everything
- Takes 30 minutes to read

### Step 2: Use the Visual Guide
📺 `CPANEL_VISUAL_GUIDE.md`
- Shows screenshots/layouts
- Shows where to click
- Quick reference

### Step 3: Print the Checklist
✅ `QUICK_INSTALLATION_CHECKLIST.md`
- Keep it handy
- Check off each step
- Don't skip anything

### Step 4: Get Help
- Contact your hosting provider (for cPanel issues)
- Contact the developer (for website issues)
- Google the error message
- Search in these FAQ answers

---

**Thank you for using Trust Tax Advisor!** 🙏

Questions? Review these guides first, then reach out for help!
