Projet

Général

Profil

Révision bceb9b7a

Ajouté par Florent Torregrosa il y a environ 9 ans

Update core to 7.35

Voir les différences:

drupal7/modules/simpletest/tests/system_test.module
106 106
    'type' => MENU_CALLBACK,
107 107
  );
108 108

  
109
  $items['system-test/get-destination'] = array(
110
    'title' => 'Test $_GET[\'destination\']',
111
    'page callback' => 'system_test_get_destination',
112
    'access callback' => TRUE,
113
    'type' => MENU_CALLBACK,
114
  );
115

  
116
  $items['system-test/request-destination'] = array(
117
    'title' => 'Test $_REQUEST[\'destination\']',
118
    'page callback' => 'system_test_request_destination',
119
    'access callback' => TRUE,
120
    'type' => MENU_CALLBACK,
121
  );
122

  
109 123
  return $items;
110 124
}
111 125

  
......
420 434
  system_authorized_init('system_test_authorize_run', drupal_get_path('module', 'system_test') . '/system_test.module', array(), $page_title);
421 435
  drupal_goto($authorize_url);
422 436
}
437

  
438
/**
439
 * Page callback to print out $_GET['destination'] for testing.
440
 */
441
function system_test_get_destination() {
442
  if (isset($_GET['destination'])) {
443
    print $_GET['destination'];
444
  }
445
  // No need to render the whole page, we are just interested in this bit of
446
  // information.
447
  exit;
448
}
449

  
450
/**
451
 * Page callback to print out $_REQUEST['destination'] for testing.
452
 */
453
function system_test_request_destination() {
454
  if (isset($_REQUEST['destination'])) {
455
    print $_REQUEST['destination'];
456
  }
457
  // No need to render the whole page, we are just interested in this bit of
458
  // information.
459
  exit;
460
}

Formats disponibles : Unified diff