- Add
"ocramius/ocra-lorem-module": "dev-master"
to yourcomposer.json
- Run
php composer.phar install
- Enable the module in your
config/application.config.php
by addingOcraLoremModule
tomodules
In your view scripts, simply write following
<?php
echo $this->lorem();
// 10000 lorem!
echo $this->lorem(10000);
LoremPixel is also supported:
<?php
echo $this->loremPixel();
Will produce something like
<img src="http://lorempixel.com/640/480/" alt="Lorem Pixel"/>
<?php
echo $this->loremPixel(300, 200, false, 'sports', 'Dummy Text', 2);
Will produce something like