maxodrom / yii2-seo
Yii2 SEO compoments
Installs: 61
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:project
Requires
- yiisoft/yii2: ~2.0.0
Requires (Dev)
- codeception/codeception: ~2.0
- codeception/specify: ~1.1
- codeception/verify: ~1.0
- phpunit/phpunit: ^7.0
- yiisoft/yii2-coding-standards: ~2.0.0
- yiisoft/yii2-debug: ~2.0.0
- yiisoft/yii2-faker: ~2.0.0
- yiisoft/yii2-gii: ~2.0.0
This package is not auto-updated.
Last update: 2024-11-06 02:23:28 UTC
README
Yii2 SEO components is a package with some useful classes which are provided with frequently used methods to work with and processing SEO texts.
SeoText class
Provides useful methods for source text processing and gathering statistical info about processed text.
use maxodrom\yii2seo\components\SeoText; // instantiate new SeoText object $seoText = new SeoText($model->textField); // get total words in our text $totalWords = $seoText->getWordsCount(); // get total characters count (including different spaces chars) $totalCharacters = $seoText->getTotalCharactersCount(); // get only word's characters count $wordCharacters = $seoText->getCharactersCount(); // get all spaces count $totalSpaces = $seoText->getSpacesCount();