You are here

function _substr in Coder 7.2

Returns a sub string.

Parameters

string $text: ???

int $start: ???

int $length: ???

Return value

??? ???

See also

drupal_substr()

8 calls to _substr()
do_coder_reviews in coder_review/coder_review.common.inc
Performs coder reviews for multiple code review definition files.
_coder_review_6x_callback in coder_review/includes/coder_review_6x.inc
Define the rule callbacks for 6.x, see do_coder_review_callback().
_coder_review_drush_is_patch_arg in coder_review/coder_review.drush.inc
Handle patch reviews.
_coder_review_page_form_includes in coder_review/coder_review.module
Adds results to form definition for display on the coder review page.
_coder_review_read_and_parse_file in coder_review/coder_review.common.inc
Parses and reads source files into a format for easier review validation.

... See full list

File

coder_review/coder_review.common.inc, line 1609
Common functions used by both the drush and form interfaces.

Code

function _substr($text, $start, $length = NULL) {
  if (function_exists('drupal_substr')) {
    return drupal_substr($text, $start, $length);
  }
  if ($length === NULL) {
    $length = strlen($text) - $start;
  }
  return substr($text, $start, $length);
}