jqgrid date formatter from and to formats - Stack Overflow

I have the date coming in as 30-Oct-24 and I need it displayed as 30-Oct-2024 and also need to be able

I have the date coming in as 30-Oct-24 and I need it displayed as 30-Oct-2024 and also need to be able to sort by date

I have this code but it's not working and showing gibberish strings instead

 formatter: 'date', formatoptions: { srcformat: 'd-MMM-yy', newformat: 'dd-MMM-yyyy' }, sorttype: 'date'

Is there a list of date formats for JqGrid that I can find somewhere? This should work but does not.

I have the date coming in as 30-Oct-24 and I need it displayed as 30-Oct-2024 and also need to be able to sort by date

I have this code but it's not working and showing gibberish strings instead

 formatter: 'date', formatoptions: { srcformat: 'd-MMM-yy', newformat: 'dd-MMM-yyyy' }, sorttype: 'date'

Is there a list of date formats for JqGrid that I can find somewhere? This should work but does not.

Share Improve this question asked Nov 21, 2024 at 1:53 sarsnakesarsnake 27.7k62 gold badges185 silver badges294 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

jqGrid follow the php date formatting. This is described into the documentation

In your case you can try with:

... srcformat : 'd-M-y', newformat : 'd-M-Y' ,...

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1742318540a4421333.html

相关推荐

  • jqgrid date formatter from and to formats - Stack Overflow

    I have the date coming in as 30-Oct-24 and I need it displayed as 30-Oct-2024 and also need to be able

    11小时前
    20

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信