<?php
require_once $_SERVER['DOCUMENT_ROOT'] . '/include/common.php';

// 定义常量
if (isset($apiCredentials['aliyunsms_akid'], $apiCredentials['aliyunsms_akst'], $apiCredentials['aliyunsms_signname'], $apiCredentials['aliyunsms_notice1'], $apiCredentials['aliyunsms_notice2'], $apiCredentials['aliyunsms_notice3'], $apiCredentials['aliyunsms_notice4'])) {
    // 使用 const 定义常量
    define('aliyunsms_akid', $apiCredentials['aliyunsms_akid']); 
    define('aliyunsms_akst', $apiCredentials['aliyunsms_akst']); 
    define('aliyunsms_signname', $apiCredentials['aliyunsms_signname']); 
    define('aliyunsms_notice1', $apiCredentials['aliyunsms_notice1']); 
    define('aliyunsms_notice2', $apiCredentials['aliyunsms_notice2']); 
    define('aliyunsms_notice3', $apiCredentials['aliyunsms_notice3']); 
    define('aliyunsms_notice4', $apiCredentials['aliyunsms_notice4']); 
} else {
    throw new Exception("API credentials not found."); // 如果没有找到，则抛出异常
}
?>
