src
1 year ago
.gitignore
4 years ago
README.md
3 years ago
composer.json
2 years ago
composer.lock
3 years ago
README.md
25 lines
| 1 | ## Image optimizer package |
| 2 | ### Usage |
| 3 | |
| 4 | #### Call Init::getInstance() method before plugins_loaded hook. It contains rest init etc. |
| 5 | ```angular2html |
| 6 | include_once 'vendor/autoload.php'; |
| 7 | |
| 8 | \TenWebIO\PreInit::check($origin = 'booster || io'); |
| 9 | ``` |
| 10 | |
| 11 | #### This is a method for bulk optimization |
| 12 | ```angular2html |
| 13 | use TenWebIO\CompressService; |
| 14 | $compress = new CompressService(); |
| 15 | $compress->compressBulk(); |
| 16 | ``` |
| 17 | |
| 18 | #### This is a method for single optimization |
| 19 | ```angular2html |
| 20 | use TenWebIO\CompressService; |
| 21 | $compress = new CompressService(); |
| 22 | $compress->compressOne($post_id); |
| 23 | ``` |
| 24 | |
| 25 |