Jump to content

Convert Numeric Month to Name Problem


Recommended Posts


$mydt=$mymm.','.$mydd.','.$myyr;
print("$mydt<br>");  ------------------>= 1,1,2020
$myjd=gregoriantojd($mydt);
print("$myjd<br>");  ------------------>= blank (why???)
$myname=jdmonthname($myjd,0);
print("$myname<br>");  ---------------->= blank (why???)

W3 Documentation:
$jd=gregoriantojd(1,13,1998);
echo jdmonthname($jd,0);  ------------>= Jan

It seems to me my code agrees with the documentation but it doesn't work.

 

Link to post
Share on other sites

I thought I was passing 3 integers via $mydt because it contains "1,1,2020"

I've made the change to pass 3 integers ($mymm,$mydd,$myyr) and it works fine.

Many thanks,

Mickey

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...