# SMTP Credentials Setup Guide

## ⚠️ IMPORTANT - Pehla Kaam (Abhi Karein)

**Gmail App Password revoke karein:**
1. Gmail.com jaayein → Google Account → Security
2. "App passwords" section mein jaayein
3. "Repair CRM" ya koi bhi linked app password **delete/revoke** karein
4. Naya App Password banayein (2-Step Verification on hona chahiye)

## Environment Variable Setup (WAMP/XAMPP)

### Option 1: Apache httpd.conf ya .htaccess mein (Recommended)
```apache
# httpd.conf ya VirtualHost mein:
SetEnv SMTP_USER "your@gmail.com"
SetEnv SMTP_PASS "your_new_app_password"
```

### Option 2: PHP .env file (project root mein banayein: repair_crm/.env)
```
SMTP_USER=your@gmail.com
SMTP_PASS=your_new_app_password
```
Phir config.php mein add karein:
```php
$env = parse_ini_file(__DIR__ . '/.env');
define('SMTP_USER', $env['SMTP_USER'] ?? '');
define('SMTP_PASS', $env['SMTP_PASS'] ?? '');
```

### Option 3: php.ini mein (server-level)
```ini
; php.ini mein add karein:
; [Repair CRM SMTP]
; SMTP credentials environment variables ke through set karein
```

## .gitignore mein add karein
```
.env
logs/
config/config.php
```

## ✅ Verification
config.php mein ab yeh hona chahiye:
```php
define('SMTP_USER', getenv('SMTP_USER') ?: '');
define('SMTP_PASS', getenv('SMTP_PASS') ?: '');
```
