I had to enter couple of millions of dummy text entries (with titles and contents) in a database so i created this small PHP script that takes latin letters and sort them out in words. It has some properties to adjust and also a definition of letters and punctuation used. I KNOW, its not perfect but I just wanted to make something automatic, not perfect tool and still it will suite you fine if you want to generate vast amounts of dummy text or just are tired of loripsuming.
function generateDummyText($textLength, $sentenceMinLength, $sentenceMaxLength, $wordMinLength, $wordMaxLength) {
$textOutput = '';
$textCounter = 0;
$letters = 'abcdefghijklmnoprstuvwxyz';
$punctuation = '.!?';
while ($textCounter<$textLength) { $sentenceLength = rand($sentenceMinLength, $sentenceMaxLength); $firstWord = true; $firstLetter = true; for ($sentenceCounter = $sentenceLength; $sentenceCounter>0; $sentenceCounter--) {
if ($firstWord==false) {
$textOutput .= (rand(0,10)==0) ? ', ' : ' ';
}
$wordLength = rand($wordMinLength, $wordMaxLength);
for ($wordCounter = $wordLength; $wordCounter>0; $wordCounter--) {
$letter = $letters[rand(0,(strlen($letters)-1))];
if ($firstLetter==false) {
$textOutput .= $letter;
} else {
$textOutput .= strtoupper($letter);
$firstLetter = false;
}
$textCounter++;
}
$firstWord=false;
}
$textOutput .= $punctuation[rand(0,(strlen($punctuation)-1))].' ';
}
return trim($textOutput);
}
Attributes are pretty selfexplainable, but anyway, here is an example.
$textLength=3000;
$wordMinLength = 3;
$wordMaxLength = 7;
$sentenceMinLength = 20;
$sentenceMaxLength = 100;
feel free to update, change, upgrade, improve or whatever. cheers!




I like the way you conduct your posts. Hmm…
I was wondering if you ever considered changing the layout of your blog? Its very well written; I love what youve got to say. But maybe you could a little more in the way of content so people could connect with it better. Youve got an awful lot of text for only having one or two images. Maybe you could space it out better?
Hey it is increadible,how can you know that thing?
That is a good tip particularly to those fresh to the blogosphere. Short but very accurate information?Many thanks for sharing this one. A must read post!
thank you !! very helpful put up! http://www.bcl.getlisted.co.nz/
That’s what i call “great post”. Thank you so much.
That’s a great post. Thank you so much.
That’s what i call “great post”. Thank you so much.
Hello Sir! Very interesting read and perfectly designed blog !
Hello There. I found your blog using msn. This is an extremely well written article. I’ll make sure to bookmark it and come back to read more of your useful information. Thanks for the post. I’ll definitely return.
Hello there, just became aware of your weblog by way of Google, and found that it’s truly informative. I am going to watch out for brussels. I will appreciate should you continue this in future. A great deal of individuals will be benefited from your writing. Cheers!
Enjoyed reading through this, very good stuff, thankyou . “We swallow greedily any lie that flatters us, but we sip little by little at a truth we find bitter.” by Denis Diderot.
I conceive this site has got some real fantastic details for everyone : D.
That’s what i call “great post”. Thank you so much.
excellent internet project! good luck and prosperity!
That’s a great post. Thank you so much.
I think a visualized presentation can be improved then simply a trouble-free text, if information are defined in pictures one can effortlessly be familiar with these.
Zune and iPod: Most nation weigh against the Zune to the Touch, nevertheless behind bearing in mind how slim and surprisingly minor and effortless it is, I think about it to live a rather exclusive mixture that combines qualities of both the Touch and the Nano. It’s same unusual and lovely OLED screen is somewhat minor than the touch screen, but the player itself feels quite a bit smaller and lighter. It weighs about 2/3 as a large amount, and is noticeably slighter in width and height, little being emphatically a hair thicker.
That’s what i call “great post”. Thank you so much.
Thank you for give really good informations. Your web site is goodI am impressed by the data which you have on this blog. It shows how nicely you comprehend this topic. Bookmarked this page, will come back for more. You, my friend, ROCK! I identified just the information I already searched everywhere and just couldn
That’s what i call “great post”. Thank you so much.
Absolutly accept you! That’s a super subject matter which match the subjest I major in! It’s useful really! Thank you!
Have you guys ever considered he may have personal experience with this? It was well written afterall.
Excellent post, mate! Thanks for the useful information
It’s difficult to find experienced people on this subject, and you appear to be you know what you’re talking about! Thanks
There are some fascinating closing dates on this article but I don’t know if I see all of them middle to heart. There’s some validity however I will take maintain opinion till I look into it further. Good article , thanks and we want more! Added to FeedBurner as well
Thanks for all of the labor on this site. Debby enjoys carrying out internet research and it’s really obvious why. A number of us hear all relating to the compelling method you offer informative secrets through the web site and in addition invigorate response from people about this concept then our simple princess is discovering a whole lot. Have fun with the remaining portion of the new year. You’re the one carrying out a superb job.
That’s a great post. Thank you so much.
That’s a great post. Thank you so much.
Hi there, just became alert to your blog through Google, and found that it is truly informative. I’m going to watch out for brussels. I will be grateful if you continue this in future. A lot of people will be benefited from your writing. Cheers!
I like this weblog its a master peace ! Glad I noticed this on google. “Live…..Laugh…..GOLF” by Kathryn Schaefer Plaum.