Php: how to generate a download list by year, month, and day. php: how to generate a list by year, month, and day.

Source: Internet
Author: User
Php generates a download list by year, month, and day. php generates a list by year, month, and day. Php: how to generate a download list by year, month, and day. php: how to generate a download list by year, month, and day. Share it with you for your reference. The specific implementation method is as follows: php generates the download list by year, month, and day, and php generates the list by year, month, and day.

This example describes how php generates a download list by year, month, and day. Share it with you for your reference. The specific implementation method is as follows:

The code is as follows: function mdy ($ mid = "month", $ did = "day", $ yid = "year", $ mval, $ dval, $ yval)
{
If (empty ($ mval) $ mval = date ("m ");
If (empty ($ dval) $ dval = date ("d ");
If (empty ($ yval) $ yval = date ("Y ");
$ Months = array (1 => "January", 2 => "February", 3 => "March", 4 => "marshl", 5 => "May ", 6 => "June", 7 => "July", 8 => "August", 9 => "September", 10 => "October ", 11 => "November", 12 => "December ");
$ Out ="";Foreach ($ months as $ val => $ text)If ($ val = $ mval) $ out. ="$ Text";Else $ out. ="$ Text";$ Out. ="";
$ Out. ="";For ($ I = 1; $ I <= 31; $ I ++)If ($ I = $ dval) $ out. ="$ I";Else $ out. ="$ I";$ Out. ="";
$ Out. ="";For ($ I = date ("Y"); $ I <= date ("Y") + 2; $ I ++)If ($ I = $ yval) $ out. ="$ I";Else $ out. ="$ I";$ Out. ="";
Return $ out;
}

I hope this article will help you design javascript programs.

In this example, php generates a download list by year, month, and day. Share it with you for your reference. The specific implementation method is as follows...

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.