---
title: "php取得某一日期的上月和下月"
author: "xcfcky"
date: "2013-04-17T15:13:07Z"
tags: []
categories: ["编程语言"]
slug: "php"
draft: false
lastmod: "2013-04-17T15:13:07Z"
id: 1848902
url: "https://xcfcky.iteye.com/blog/1848902"
---

$kakuteiYmData = date('Ym',strtotime('-1 month', strtotime($kakuteiYm.'01')));

$kakuteiYmData = date('Ym',strtotime('-1 month', strtotime(20130401)));