A comprehensive **Laravel 12nd news management system with advanced features including user authentication, admin dashboard, API endpoints, social login, real-time notifications, and more.
- Features
- Technology Stack
- Installation
- Project Structure
- API Documentation
- User Features
- Admin Features](#-admin-features)
- Advanced Features
- Database Structure
- Security Features
- Development Tools
- Multi-Guard Authentication: Separate authentication for users, admins, and API
- Email Verification: Required email verification for users
- Social Login: Google, Facebook, GitHub, and other social providers
- OTP System: One-time password for admin password reset
- Role-Based Access Control: Custom roles and permissions for admins
- Password Reset: Secure password reset with email verification
- User Registration & Login: Complete user authentication system
- Profile Management: User profiles with avatar, bio, location
- User Dashboard: Personal dashboard for managing posts and settings
- User Status Management: Active/inactive user status
- Social Media Integration: Social login with profile sync
- Post Creation & Management: Rich text editor with image support
- Category System: Hierarchical categories with status management
- Comment System: Nested comments with moderation
- Image Management: Multiple image upload with individual deletion
- SEO Optimization: Sluggable URLs and meta tags
- Content Status: Active/inactive content management
- Responsive Design: Modern, mobile-friendly interface
- Search Functionality: Advanced search across posts and categories
- Newsletter Subscription: Email subscription system
- Contact System: Contact form with admin management
- Real-time Updates: Livewire components for dynamic content
- Social Sharing: Social media integration
- Comprehensive Dashboard: Statistics and analytics
- User Management: Complete user administration
- Content Moderation: Post and comment moderation
- Settings Management: Website configuration
- Role Management: Admin roles and permissions
- Reports & Analytics: Charts and statistics
- RESTful API: Complete API with authentication
- Rate Limiting: API rate limiting for security
- Resource Collections: Structured API responses
- User Account Management: API endpoints for user operations
- Content API: Posts, categories, and comments via API
- **Laravel12Main PHP framework
- **PHP 80.2odern PHP features
- MySQL/PostgreSQL - Database
- Redis - Caching and sessions
- Laravel Sanctum 4.0 - API authentication
- **Laravel Socialite 5.21Social media login
- Laravel OTP 2.0 - One-time password system
- Laravel Breeze 2.3 - Authentication scaffolding
- **Livewire3.6al-time components
- Bootstrap - CSS framework
- jQuery - JavaScript library
- Slick Slider - Carousel/slider
- Summernote - Rich text editor
- DataTables - Interactive tables
- Chart.js - Charts and graphs
- **Laravel Telescope 50.9ication monitoring
- Laravel Debugbar 3.15 - Debug toolbar
- Laravel Pint 1.13 - Code formatting
- Pest 3.8 - Testing framework
- **Eloquent Sluggable 12.0 SEO-friendly URLs
- Laravel Charts 0.2.3 - Chart generation
- PHP Flasher 2.1 - Alert messages
- Predis 2.0 - Redis client
- **Pusher7.2time communication
- PHP 80.2 higher
- Composer
- Node.js & NPM
- MySQL/PostgreSQL
- Redis (optional)
- Clone the repository
git clone <repository-url>
cd blog_news_system
```2l PHP dependencies**
```bash
composer install3 Install Node.js dependencies
npm install
```4*Environment setup**
```bash
cp .env.example .env
php artisan key:generate- Configure database
Edit
.envfile with your database credentials:
DB_CONNECTION=mysql
DB_HOST=127.000.1
DB_PORT=3306
DB_DATABASE=blog_news_system
DB_USERNAME=your_username
DB_PASSWORD=your_password- Run migrations and seeders
php artisan migrate
php artisan db:seed7Storage setup
php artisan storage:link8 Build assets
npm run build- Start the server
php artisan serveblog_news_system/
βββ app/
β βββ Http/
β β βββ Controllers/
β β β βββ Admin/ # Admin controllers
β β β βββ Api/ # API controllers
β β β βββ Auth/ # Authentication controllers
β β β βββ Frontend/ # Frontend controllers
β β βββ Middleware/ # Custom middleware
β β βββ Requests/ # Form requests
β β βββ Resources/ # API resources
β βββ Models/ # Eloquent models
β βββ Livewire/ # Livewire components
β βββ Notifications/ # Email notifications
β βββ Jobs/ # Background jobs
β βββ Repositories/ # Repository pattern
β βββ Interfaces/ # Service interfaces
β βββ Utils/ # Utility classes
β βββ Providers/ # Service providers
βββ database/
β βββ migrations/ # Database migrations
β βββ seeders/ # Database seeders
β βββ factories/ # Model factories
βββ resources/
β βββ views/ # Blade templates
βββ routes/ # Route definitions
βββ public/ # Public assets
API Version: https://documenter.getpostman.com/view/33761394zHD
GET /api/posts- Get all posts with paginationGET /api/posts/{keyword}- Search posts by keywordGET /api/posts/show/{slug}- Get specific postGET /api/posts/comments/{slug}- Get post commentsGET /api/categories- Get all categoriesGET /api/categories/{slug}/posts- Get category postsGET /api/settings- Get website settingsGET /api/related-sites- Get related sitesPOST /api/contact/store- Submit contact form
POST /api/auth/register- User registrationPOST /api/auth/login- User loginDELETE /api/auth/logout- User logoutPOST /api/auth/email/verify- Verify emailGET /api/auth/email/resend- Resend verification emailPOST /api/forget-password/email- Forgot passwordPOST /api/reset-password- Reset password
GET /api/account/user- Get user profilePUT /api/account/update-settings/{user_id}- Update user settingsPUT /api/account/change-password/{user_id}- Change passwordGET /api/account/posts- Get user postsPOST /api/account/posts/store/post- Create user postPUT /api/account/posts/update/post/{id}- Update user postDELETE /api/account/posts/delete/post/{id}- Delete user postGET /api/account/posts/post/{id}/comments- Get post commentsPOST /api/account/posts/comments/store- Store comment
- User registration with email verification
- Login/logout functionality
- Social media login (Google, Facebook, GitHub)
- Password reset via email
- Remember me functionality
- Personal profile with avatar upload
- Bio, location, and contact information
- Username customization
- Profile privacy settings
- Create and edit posts with rich text editor
- Multiple image upload for posts
- Category selection
- Comment enable/disable options
- Post status management
- Personal dashboard with statistics
- Post management (create, edit, delete)
- Comment management
- Notification center
- Settings management
- Comment on posts
- Search functionality
- Newsletter subscription
- Contact form submission
- Social sharing
- Comprehensive statistics and analytics
- Real-time charts and reports
- System overview
- Quick actions panel
- View all users
- User status management (active/inactive)
- User profile editing
- User statistics
- Post creation and editing
- Category management
- Comment moderation
- Image management
- Content status control
- Admin user management
- Role and permission management
- Website settings configuration
- Contact message management
- Related sites management
- Admin authentication with OTP
- Role-based access control
- Activity logging
- Security monitoring
- Livewire Integration: Real-time updates without page refresh
- Latest Posts & Comments: Live updates of recent activity
- Reports Dashboard: Real-time statistics and charts
- Notification System: Instant notifications
- Multiple Image Upload: Support for multiple images per post
- Image Optimization: Automatic image processing
- Individual Image Deletion: Delete specific images
- Image Storage: Organized file storage system
- Advanced Search: Search across posts and categories
- Keyword Filtering: Filter posts by keywords
- Category Filtering: Filter by categories
- Status Filtering: Filter by content status
- Email Notifications: New comment notifications
- OTP Notifications: Password reset and verification
- Admin Notifications: System notifications
- User Notifications: Personal notifications
- Sluggable URLs: SEO-friendly URLs
- Meta Tags: Automatic meta tag generation
- Sitemap Generation: XML sitemap support
- Social Media Tags: Open Graph and Twitter Cards
- users - User accounts and profiles
- admins - Administrator accounts
- roles - Admin roles and permissions
- posts - Articles and news content5. categories - Content categories6*comments** - User comments on posts
- images - Post images and media8ttings** - Website configuration9ntacts** - Contact form submissions
- news_subscribers - Newsletter subscribers 11 related_sites - Related website links
- Users β Posts (One-to-Many)
- Users β Comments (One-to-Many)
- Posts β Category (Many-to-One)
- Posts β Comments (One-to-Many)
- Posts β Images (One-to-Many)
- Admins β Posts (One-to-Many)
- Admins β Role (Many-to-One)
- Multi-factor Authentication: Email verification required
- Password Hashing: Secure password storage
- Session Management: Secure session handling
- CSRF Protection: Cross-site request forgery protection
- Rate Limiting: API request throttling
- Token Authentication: Sanctum-based API auth
- Request Validation: Comprehensive input validation
- CORS Protection: Cross-origin resource sharing
- SQL Injection Prevention: Parameterized queries
- XSS Protection: Cross-site scripting prevention
- File Upload Security: Secure file handling
- Input Sanitization: Data cleaning and validation
- Laravel Telescope: Application monitoring and debugging
- Laravel Debugbar: Development debugging toolbar
- Error Logging: Comprehensive error tracking
- Performance Monitoring: Application performance tracking
- Laravel Pint: Code formatting and style
- Pest Testing: Modern testing framework
- Code Analysis: Static code analysis
- Documentation: Comprehensive code documentation
- Repository Pattern: Clean architecture implementation
- Service Providers: Modular service management
- Interface Contracts: Service interface definitions
- Dependency Injection: Inversion of control
- Redis Caching: High-performance caching
- Query Caching: Database query optimization
- View Caching: Template caching
- Route Caching: Route optimization
- Eager Loading: Optimized database queries
- Lazy Loading: On-demand resource loading
- Image Optimization: Compressed image delivery
- Asset Minification: CSS/JS optimization
- Easy Content Creation: Simple post creation and management
- Rich Interaction: Comment system and social features
- Personal Dashboard: Comprehensive user dashboard
- Mobile Responsive: Works on all devices
- Complete Control: Full content and user management
- Analytics Dashboard: Comprehensive statistics
- Role Management: Flexible permission system
- Security Features: Advanced security controls
- Clean Architecture: Well-structured codebase
- API-First Design: Comprehensive API endpoints
- Extensible System: Easy to extend and customize
- Modern Stack: Latest Laravel and PHP features
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
This project is licensed under the MIT License.
For support and questions:
- You can Contact me for any error or chat for a project For you +201212484233
- Create an issue in the repository
- Check the API documentation
- Review the Laravel documentation
** Built with π©΅ By Abdallh Elzaya t**