| @@ 641-643 (lines=3) @@ | ||
| 638 | $fields = $_POST['fields']; |
|
| 639 | $this->_errors = array(); |
|
| 640 | ||
| 641 | if (!isset($fields['title']) || trim($fields['title']) == '') { |
|
| 642 | $this->_errors['title'] = __('This is a required field'); |
|
| 643 | } |
|
| 644 | ||
| 645 | if (trim($fields['type']) != '' && preg_match('/(index|404|403)/i', $fields['type'])) { |
|
| 646 | $types = preg_split('/\s*,\s*/', strtolower($fields['type']), -1, PREG_SPLIT_NO_EMPTY); |
|
| @@ 662-665 (lines=4) @@ | ||
| 659 | } |
|
| 660 | ||
| 661 | // Check to ensure all the required section fields are filled |
|
| 662 | if (!isset($meta['navigation_group']) || strlen(trim($meta['navigation_group'])) == 0) { |
|
| 663 | $this->_errors['navigation_group'] = __('This is a required field.'); |
|
| 664 | $canProceed = false; |
|
| 665 | } |
|
| 666 | ||
| 667 | // Basic custom field checking |
|
| 668 | if (is_array($fields) && !empty($fields)) { |
|