# 🚀 Quick cPanel Upload Guide - Direct URL Fix Included

## 📥 Download Files

**Location:** `/app/frontend/uniflow-grants-website.zip` (503 KB)

This file includes the **enhanced .htaccess** that fixes direct URL access!

---

## ⚡ 5-Minute Deploy

### 1. Upload to cPanel
- Login to cPanel → File Manager
- Go to `public_html`
- Upload `uniflow-grants-website.zip`

### 2. Extract
- Right-click the zip file
- Click "Extract"

### 3. Move Files
- Open `build` folder
- Select ALL files (Ctrl+A)
- Click "Move" → Move to `/public_html/`

### 4. Enable Hidden Files (IMPORTANT!)
- Click "Settings" (top right)
- ✅ Check "Show Hidden Files (dotfiles)"
- Click "Save"

### 5. Verify .htaccess Exists
- Look for `.htaccess` file in `public_html`
- ✅ If present, you're good to go!
- ❌ If missing, see section below

### 6. Test Direct URLs
Type these URLs directly in browser:
```
https://yourdomain.com/verification
https://yourdomain.com/check-eligibility
https://yourdomain.com/about
```

✅ All should work without errors!

---

## 🔧 If .htaccess Is Missing

Create `.htaccess` file in `public_html` with this:

```apache
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_FILENAME} !-l
  RewriteRule . /index.html [L]
</IfModule>

Options -Indexes
ErrorDocument 404 /index.html
ErrorDocument 403 /index.html
ErrorDocument 500 /index.html
```

**Set permissions to 644**

---

## 🧪 Final Checklist

- [ ] Files uploaded and extracted
- [ ] Files moved from `build/` to `public_html/`
- [ ] Hidden files enabled in File Manager
- [ ] `.htaccess` exists in `public_html` folder
- [ ] Homepage loads: `https://yourdomain.com/`
- [ ] Direct URLs work: `https://yourdomain.com/verification`
- [ ] Forms load correctly on all 3 pages

---

## 🎯 What .htaccess Does

**Without .htaccess:**
- ❌ `yourdomain.com/verification` → 404 Error
- ❌ Direct URLs don't work
- ✅ Only navigation through homepage works

**With .htaccess:**
- ✅ `yourdomain.com/verification` → Works perfectly
- ✅ All direct URLs work
- ✅ Bookmarks and shared links work
- ✅ Page refresh (F5) works

---

## 📄 Complete Documentation

- **Download Guide:** `/app/DOWNLOAD_AND_DEPLOY.md`
- **Routing Fix Guide:** `/app/FIXING_CPANEL_ROUTING.md`
- **Changes Summary:** `/app/CHANGES_SUMMARY.md`

---

## ✅ You're All Set!

The `.htaccess` file in the build will automatically fix the direct URL access issue. Just upload, extract, move files, and verify!

**Questions?** Check `/app/FIXING_CPANEL_ROUTING.md` for detailed troubleshooting.
