You are here

function coder_review_i18n_po_reviews in Coder 7

Same name and namespace in other branches
  1. 7.2 coder_review/includes/coder_review_i18n_po.inc \coder_review_i18n_po_reviews()

Implements hook_reviews().

File

coder_review/includes/coder_review_i18n_po.inc, line 12
This include file implements coder functionality to check for Internationalization issues in translation files.

Code

function coder_review_i18n_po_reviews() {
  $argex = '(((\\$?)[a-zA-Z_]+((\\([^)]*\\))|\\[[^\\]]*\\])?)|[0-9]+(\\.[0-9]*)?|\'\'|"")';
  $rules = array(
    array(
      '#type' => 'callback',
      '#filename' => array(
        'po',
      ),
      '#value' => '_coder_review_translation_callback',
    ),
  );
  $review = array(
    '#title' => t('Translation files'),
    '#rules' => $rules,
    '#description' => t('experimental'),
  );
  return array(
    'i18n_po' => $review,
  );
}