# Prantor Pay - Modern Payment Gateway for WooCommerce

## 📱 Overview

Prantor Pay is a professional WooCommerce payment gateway plugin that enables online stores to accept payments from Bangladesh using multiple payment methods including Bkash, Nagad, Rocket, and card payments.

**Version:** 1.1.0  
**Requires:** WordPress 5.2+, WooCommerce 3.0+, PHP 7.2+

---

## ✨ Features

### Payment Methods
- 🏦 **Bkash** - Mobile banking payments
- 📱 **Nagad** - Instant payment service
- 🚀 **Rocket** - High-speed payments
- 💳 **Card Payments** - Visa, Mastercard, etc.

### Modern UI/UX
- 🎨 Beautiful gradient-based interface
- 📱 Fully responsive design (mobile, tablet, desktop)
- ⚡ Fast checkout experience
- 🔒 Security badges and indicators
- 🎯 Intuitive payment method selection

### Technical Features
- ✅ SSL/TLS encryption support
- 📊 Webhook support for payment verification
- 🔄 Automatic order status updates
- 🛒 Digital product support
- 📈 Multi-currency support (USD to BDT conversion)
- 🔌 Easy integration and configuration

### Admin Interface
- 🎯 Clean, modern settings page
- 📝 Comprehensive configuration options
- 🔐 Secure API key storage
- 🎨 Dark mode support
- 📊 Easy-to-understand documentation

---

## 🚀 Installation

### From WordPress Dashboard:
1. Go to **Plugins** → **Add New**
2. Upload the `prantorpay` folder
3. Click **Activate**

### Manual Installation:
1. Extract the plugin files
2. Upload to `/wp-content/plugins/prantorpay/`
3. Activate through **Plugins** menu

---

## ⚙️ Configuration

### Step 1: Basic Setup
1. Go to **WooCommerce** → **Settings** → **Payments**
2. Click on **Prantor Pay**
3. Enable the gateway by checking the **Enable/Disable** checkbox

### Step 2: API Configuration
1. Log in to your [Prantor Pay Dashboard](https://prantorpay.com/)
2. Navigate to **API Settings**
3. Copy your **API Key**
4. Paste it in the plugin's **API Key** field
5. Save changes

### Step 3: Configure Settings
- **Title:** How customers see the payment method (default: "Prantor Pay - Bkash, Nagad, Rocket")
- **Description:** Checkout page description
- **USD Rate:** Currency conversion rate (default: 110)
- **Digital Products:** Auto-complete digital product orders
- **Payment Gateway URL:** Keep as default (https://securepay.prantorpay.com/)

---

## 🎨 Design Improvements (v1.1.0)

### Frontend Design
- **Modern Card Layout:** Eye-catching payment method display
- **Gradient Background:** Professional purple gradient theme
- **Interactive Elements:** Hover effects and smooth animations
- **Security Indicators:** Visual trust badges
- **Payment Method Icons:** Clear, recognizable method selection
- **Responsive Layout:** Perfect on all screen sizes

### Admin Design
- **Structured Settings:** Organized form sections
- **Professional Typography:** Clear hierarchy and readability
- **Color-coded Alerts:** Easy-to-spot information boxes
- **Smooth Animations:** Modern fade-in effects
- **Dark Mode Support:** Automatic dark theme detection

### User Experience
- Clear payment flow visualization
- Instant visual feedback on selections
- Loading states and progress indicators
- Helpful tooltips and descriptions
- Error messages with solutions

---

## 📁 File Structure

```
prantorpay/
├── Prantorpay.php              # Main plugin file
├── readme.txt                   # Plugin readme
├── assets/
│   ├── css/
│   │   ├── prantorpay-frontend.css    # Frontend styles
│   │   └── prantorpay-admin.css       # Admin panel styles
│   ├── js/
│   │   └── prantorpay-frontend.js     # Frontend scripts
│   └── images/
│       └── prantorpay-icon.svg        # Plugin icon
└── languages/
    └── prantorpay.pot           # Translation template
```

---

## 🔧 Usage

### For Customers
1. At checkout, select **Prantor Pay** payment method
2. Choose preferred payment method (Bkash, Nagad, Rocket, Card)
3. Click **Place Order**
4. Complete payment on Prantor Pay secure gateway
5. Automatic return and order confirmation

### For Store Owners
1. Monitor payments in WooCommerce **Orders** page
2. Orders automatically update on successful payment
3. View transaction details in order notes
4. Process refunds through WooCommerce dashboard

---

## 🔐 Security

- **SSL/TLS Encryption:** All transactions are encrypted
- **API Key Protection:** Secure API key storage
- **Webhook Verification:** Payment validation
- **Transaction Verification:** Double-check payment status
- **PCI DSS Compliant:** Follows payment industry standards

---

## 🐛 Troubleshooting

### Issue: "Unable to process payment with Prantor Pay"
**Solution:**
- Verify API key is correct
- Check payment gateway URL is accessible
- Ensure WooCommerce REST API is enabled
- Review error logs in WooCommerce system status

### Issue: Orders not updating after payment
**Solution:**
- Verify webhook URL is correct
- Check WordPress cron is enabled
- Review payment verification settings
- Contact Prantor Pay support with transaction ID

### Issue: Currency conversion not working
**Solution:**
- Set correct USD to BDT rate
- Verify store currency is set to USD in WooCommerce
- Clear cache if using caching plugin

---

## 💬 Support

- 📧 **Email:** support@prantorpay.com
- 🌐 **Website:** https://prantorpay.com/
- 📱 **Support Portal:** https://prantorpay.com/support
- 🐛 **Report Issues:** Use the plugin's support forum

---

## 📝 Changelog

### Version 1.1.0
- ✨ Complete UI/UX redesign with modern gradient theme
- 🎨 Added modern CSS styling for frontend and admin
- 📱 Enhanced responsive design for mobile devices
- 🎯 New payment method display with icons
- 🔐 Added security badges and trust indicators
- ⚡ Improved checkout experience with smooth animations
- 🛠️ Better form field descriptions and help text
- 🌙 Added dark mode support for admin panel
- 📈 Enhanced admin settings interface
- 🔄 Improved form validation and error handling

### Version 1.0.0
- 🎉 Initial release
- 💳 Basic payment gateway integration
- 🔗 Webhook support
- 🛒 Order status management

---

## 📄 License

GPL v2 or later. See LICENSE file for details.

---

## 👥 Credits

**Development:** Prantor Payment Team  
**Support:** [prantorpay.com](https://prantorpay.com/)

---

## ❓ FAQ

**Q: Which payment methods are supported?**  
A: Bkash, Nagad, Rocket, and Card payments (Visa, Mastercard)

**Q: Is the plugin mobile-friendly?**  
A: Yes! The design is fully responsive and optimized for all devices.

**Q: Can I accept international payments?**  
A: Currently optimized for Bangladesh payments. USD conversion supported.

**Q: What's the transaction fee?**  
A: Check your Prantor Pay merchant account for current rates.

**Q: Is SSL required?**  
A: Yes, SSL certificate is required for production use.

---

**Last Updated:** May 2024  
**Documentation Version:** 1.1.0
