📜  php如何检查页面是否通过post访问 - PHP代码示例

📅  最后修改于: 2022-03-11 14:54:13.440000             🧑  作者: Mango

代码示例1
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
// Boom baby we a POST method.
}
if ($_SERVER['REQUEST_METHOD'] === 'GET') {
// We are a GET method.
}