0

Ive been looking for code sample regarding my question, How can I convert the current date into current week number in a month, not by year. e.g. 1st week of the month of current month, 2nd week of the month of current month, and so on.. For more details, kindly see the sample or explanation below.

April
Week 1: 1-2
Week 2: 3-4-5-6-7-8-9
Week 3: 10-11-12-13-14-15-16
Week 4: 17-18-19-20-21-22-23
Week 5: 24-**25**-26-27-28-29-30

current date: April 25, 2016

expected PHP output : 5th week of april.

which will fall to week 5 of the current month. Now the challenge here is this. How can i convert the current date into current number of week of the current month. Thank you so much Guys for your help!

Kevin
  • 41,694
  • 12
  • 53
  • 70
  • If this is a PHP question, why the javascript tag? – RobG Apr 26 '16 at 02:22
  • here's for the suffix `th, nd.. etc..` http://stackoverflow.com/questions/3109978/display-numbers-with-ordinal-suffix-in-php – Kevin Apr 26 '16 at 02:25

0 Answers0