π What's New in v1.0.2
β¨ New Features
- Dynamic Attributes Support: Now you can pass custom variables to your PHP code using shortcode attributes
- Enhanced Admin Interface: Added comprehensive examples and documentation in the admin panel
- Improved Visual Identity: Added custom menu icon for better plugin recognition
π§ Technical Improvements
- Added attribute sanitization system for enhanced security
- Implemented
extract()function for easy attribute access in PHP code - Added support for accessing attributes both as variables and array format
- Added comprehensive error handling for attribute processing
π Documentation Updates
- Added detailed examples of attribute usage
- Updated README with new features and security guidelines
- Added changelog section to track version history
- Added code examples for common use cases
π‘οΈ Security Enhancements
- Added input sanitization for all attribute values
- Added recommendations for secure attribute handling
- Improved error reporting for invalid inputs
π‘ Example Usage
[php_code id="calculator" price="10.99" quantity="3"]PHP Code:
$total = floatval($price) * intval($quantity);
echo "Total Price: $" . number_format($total, 2);π Testing Notes
- Please test attribute handling with various data types
- Verify sanitization of special characters
- Test error handling with invalid inputs
π Requirements
- WordPress 5.0 or higher
- PHP 7.2 or higher
π Upgrade Instructions
- Backup your existing plugin data
- Deactivate and delete the old version
- Install and activate the new version
- No database migration required