You are here

function styleguide_paragraph in Style Guide 7

Same name and namespace in other branches
  1. 6 styleguide.module \styleguide_paragraph()

Generate paragraph(s) of random text.

Parameters

$size: The number of paragraphs to return.

Return value

HTML paragraphs.

6 calls to styleguide_paragraph()
aggregator_styleguide in modules/aggregator.inc
Implements hook_styleguide().
comment_styleguide in modules/comment.inc
Implements hook_styleguide().
hook_styleguide in ./styleguide.api.php
Register a style guide element for display.
styleguide_form in ./styleguide.module
Sample form, showing all elements.
styleguide_sentence in ./styleguide.module
Generate a random sentence.

... See full list

File

./styleguide.module, line 361

Code

function styleguide_paragraph($size = 5) {
  $text = styleguide_lorem($size, 0, 'mixed', TRUE, TRUE, TRUE);
  $output = '';
  foreach ($text as $item) {
    $output .= '<p>' . trim($item) . '</p>';
  }
  return $output;
}