extra_field.ajax.php 799 B

1234567891011121314151617181920212223
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. $language_file = array('admin', 'registration', 'userInfo');
  4. require_once '../global.inc.php';
  5. $action = $_GET['a'];
  6. switch ($action) {
  7. case 'get_second_select_options':
  8. $type = isset($_REQUEST['type']) ? $_REQUEST['type'] : null;
  9. $field_id = isset($_REQUEST['field_id']) ? $_REQUEST['field_id'] : null;
  10. $option_value_id = isset($_REQUEST['option_value_id']) ? $_REQUEST['option_value_id'] : null;
  11. if (!empty($type) && !empty($field_id) && !empty($option_value_id)) {
  12. $field_options = new ExtraFieldOption($type);
  13. echo $field_options->get_second_select_field_options_by_field($field_id, $option_value_id, true);
  14. }
  15. break;
  16. default:
  17. exit;
  18. break;
  19. }
  20. exit;