# Format datetime

**URL:** https://community.mp3tag.de/t/format-datetime/14217
**Category:** Support
**Created:** [December 11, 2012, 4:22pm UTC](https://community.mp3tag.de/t/format-datetime/14217 "2012-12-11T16:22:29Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![antanof](https://community.mp3tag.de/user_avatar/community.mp3tag.de/antanof/32/408_2.png) [@antanof](https://community.mp3tag.de/u/antanof)
#### Post date: [December 11, 2012, 4:22pm UTC](https://community.mp3tag.de/t/format-datetime/14217/1 "2012-12-11T16:22:29Z")

</div>

Hello,  
i have an other little problem :  
I want an xml export datetime like :  
2010-12-11T18:14:30  
but mp3tag give me  
2010-12-11 18:14:30

how can i transform the format ? can i do :

$regexp(%\_datetime%,(\d\d\d\d).(\d\d).(\d\d)T(\d\d).(\d\d).(\d\d),$1.$2.$3.$4.$5.$6) ??

The simplest would be to:  
%\_date%T%\_time%  
but %\_time% don't exist...

---

<div class="post-metadata">

### Author: ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)
#### Post date: [December 11, 2012, 4:31pm UTC](https://community.mp3tag.de/t/format-datetime/14217/2 "2012-12-11T16:31:35Z")

</div>

> [@antanof](#):
>
> ... I want an xml export datetime like :  
> 2010-12-11T18:14:30 but mp3tag give me 2010-12-11 18:14:30  
> how can i transform the format ? ...

Simply replace the one space with letter "T"  
$replace(%\_datetime%,' ','T')

DD.20121211.1827.CET

---

<div class="post-metadata">

### Author: ![antanof](https://community.mp3tag.de/user_avatar/community.mp3tag.de/antanof/32/408_2.png) [@antanof](https://community.mp3tag.de/u/antanof)
#### Post date: [December 11, 2012, 4:36pm UTC](https://community.mp3tag.de/t/format-datetime/14217/3 "2012-12-11T16:36:47Z")

</div>

🙂 thanks

---

<div class="post-metadata">

### Author: ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)
#### Post date: [February 9, 2026, 12:24pm UTC](https://community.mp3tag.de/t/format-datetime/14217/4 "2026-02-09T12:24:13Z")

</div>


