# Feature Request: Insert Date ONLY button

**URL:** <https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878>\
**Category:** Features\
**Created:** [15 February 2021 09:47 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878 "2021-02-15T09:47:49Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![herdsothom](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/herdsothom/32/5040_2.png) [@herdsothom](https://discourse.joplinapp.org/u/herdsothom)\
**Post date:** [15 February 2021 09:47 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/1 "2021-02-15T09:47:49Z")

</div>

Hi all,

A feature I use very frequently is the 'Insert Date Time' button on desktop.  
Most of the time however, I do not need the 'Time' component of the DateTime.

It would be excellent to have a button to insert just the Date, or potentially even shift clicking the button inserts the date only?

I am happy to implement this request myself and raise a PR.  
I'm first interested to know if there is appetite for this, and what the preferred solution is?

Thanks!

---

<div class="post-metadata">

**Author:** ![roman\_r\_m](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/roman_r_m/32/3297_2.png) [@roman\_r\_m](https://discourse.joplinapp.org/u/roman_r_m)\
**Post date:** [15 February 2021 11:20 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/2 "2021-02-15T11:20:09Z")

</div>

Could be done as a plugin - would be much faster in terms of dev time.

---

<div class="post-metadata">

**Author:** ![whitewall](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/whitewall/32/6018_2.png) [@whitewall](https://discourse.joplinapp.org/u/whitewall)\
**Post date:** [15 February 2021 12:44 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/3 "2021-02-15T12:44:38Z")

</div>

Hmm. I never knew I wanted that. Great idea. I never need the time.

---

<div class="post-metadata">

**Author:** ![herdsothom](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/herdsothom/32/5040_2.png) [@herdsothom](https://discourse.joplinapp.org/u/herdsothom)\
**Post date:** [16 February 2021 01:35 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/4 "2021-02-16T01:35:37Z")

</div>

Hmm, that sounds like a good first step.  
Perhaps I start by implementing it as a plugin, and if there is appetite for it, could be consolidated into the base application. It can be a bit of a pain installing plugins for all these sorts of things

---

<div class="post-metadata">

**Author:** ![herdsothom](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/herdsothom/32/5040_2.png) [@herdsothom](https://discourse.joplinapp.org/u/herdsothom)\
**Post date:** [16 February 2021 09:18 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/5 "2021-02-16T09:18:34Z")

</div>

I've created a plugin for it!

> [@Plugin: Insert Date](https://discourse.joplinapp.org/t/plugin-insert-date/14902):
>
> This plugin adds a button to the editor toolbar that, when pressed, inserts the current date into the editor. Install by searching for 'Insert Date' in Joplin Preferences -\> Plugins. [InsertDateGIF] As described in [this forum post](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/4), most of the time I use the existing 'Insert Date Time' button, I dont need the exact timestamp, and it is overkill. This plugin addresses that. Github Repository: [GitHub - herdsothom/joplin-insert-date](https://github.com/herdsothom/joplin-insert-date)

---

<div class="post-metadata">

**Author:** ![whitewall](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/whitewall/32/6018_2.png) [@whitewall](https://discourse.joplinapp.org/u/whitewall)\
**Post date:** [16 February 2021 09:35 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/6 "2021-02-16T09:35:03Z")

</div>

Yay! That's great. Good on ya!

Any chance of a keyboard shortcut? In for a penny, in for a pound I say.

---

<div class="post-metadata">

**Author:** ![herdsothom](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/herdsothom/32/5040_2.png) [@herdsothom](https://discourse.joplinapp.org/u/herdsothom)\
**Post date:** [16 February 2021 09:51 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/7 "2021-02-16T09:51:43Z")

</div>

Yes, thats a good suggestion. Any preference for the shortcut?

---

<div class="post-metadata">

**Author:** ![whitewall](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/whitewall/32/6018_2.png) [@whitewall](https://discourse.joplinapp.org/u/whitewall)\
**Post date:** [16 February 2021 11:06 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/8 "2021-02-16T11:06:02Z")

</div>

Is it possible to have it be a part of the built in shortcut system so users are able to re-assign it? I think the core time-date feature is ctrl shift t and I've re-assigned it as ctrl t since I wasn't using whatever ctrl t was.

Thanks!

---

<div class="post-metadata">

**Author:** ![antoniopaolini](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/antoniopaolini/32/12225_2.png) [@antoniopaolini](https://discourse.joplinapp.org/u/antoniopaolini)\
**Post date:** [21 February 2021 11:46 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/9 "2021-02-21T11:46:20Z")

</div>

To insert today's date we can also use templates.  
For example  
`{{#custom_datetime}}YYYY-MM-DD{{/custom_datetime}}`  
It's more flexible, we can choose format and also there's a shortcut, CTRL-ALT-i

It would be useful if this plugin allowed to choose other dates as well.

---

<div class="post-metadata">

**Author:** ![derikb](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/derikb/32/2796_2.png) [@derikb](https://discourse.joplinapp.org/u/derikb)\
**Post date:** [21 February 2021 14:02 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/10 "2021-02-21T14:02:54Z")

</div>

Somehow I totally missed that insert date/time button and am thrilled it can be used in the note title. Thanks for pointing it out. I use dated title notes for a journal and this will save me some time starting entries.

---

<div class="post-metadata">

**Author:** ![skim1124](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/skim1124/32/7296_2.png) [@skim1124](https://discourse.joplinapp.org/u/skim1124)\
**Post date:** [21 February 2021 15:25 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/11 "2021-02-21T15:25:43Z")

</div>

Yes, another vote for the option to enter YYYY-MM-DD or even just YY-MM-DD.

---

<div class="post-metadata">

**Author:** ![duxswhatduxs](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/duxswhatduxs/32/16771_2.png) [@duxswhatduxs](https://discourse.joplinapp.org/u/duxswhatduxs)\
**Post date:** [21 February 2021 16:35 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/12 "2021-02-21T16:35:09Z")

</div>

A vote for MMMM d, yyyy?

---

<div class="post-metadata">

**Author:** ![tessus](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/tessus/32/13_2.png) [@tessus](https://discourse.joplinapp.org/u/tessus)\
**Post date:** [21 February 2021 17:41 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/13 "2021-02-21T17:41:26Z")

</div>

@skim1124@duxswhatduxs version 1.0.1 of the plugin takes the date time setting of Joplin.

---

<div class="post-metadata">

**Author:** ![antoniopaolini](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/antoniopaolini/32/12225_2.png) [@antoniopaolini](https://discourse.joplinapp.org/u/antoniopaolini)\
**Post date:** [21 February 2021 18:39 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/14 "2021-02-21T18:39:37Z")

</div>

With templates it is easy to select what do you want.  
For example, you can do thinks like:

```auto
{{#custom_datetime}}YYYY-MM-DD - dddd{{/custom_datetime}}
{{#custom_datetime}}LLL{{/custom_datetime}}
{{#custom_datetime}}LLLL{{/custom_datetime}}
Week {{#custom_datetime}}W-E{{/custom_datetime}}
<u>{{#custom_datetime}}LLLL{{/custom_datetime}} — ( __W{{#custom_datetime}}W{{/custom_datetime}}__ )</u>

```

and get:

> 2021-02-21 - domenica  
> 21 febbraio 2021 19:27  
> domenica 21 febbraio 2021 19:27  
> Week 7-7  
> \<u\>domenica 21 febbraio 2021 19:29 — (\_\_W7\_\_)\</u\>

The format came from moment.js, as said in the [Joplin website](https://joplinapp.org/#note-templates).

---

<div class="post-metadata">

**Author:** ![skim1124](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/skim1124/32/7296_2.png) [@skim1124](https://discourse.joplinapp.org/u/skim1124)\
**Post date:** [22 February 2021 00:46 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/15 "2021-02-22T00:46:46Z")

</div>

Ah, got it! Thanks.

---

<div class="post-metadata">

**Author:** ![skim1124](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/skim1124/32/7296_2.png) [@skim1124](https://discourse.joplinapp.org/u/skim1124)\
**Post date:** [22 February 2021 03:16 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/16 "2021-02-22T03:16:33Z")

</div>

I took at a look at the note template page, but it's not clear to me how to use custom\_datetime or moments.js. What would I have to do if I wanted to quickly insert YYMMDD (e.g. 210225 for Feb 25, 2021) in the editor pane or the title bar?

---

<div class="post-metadata">

**Author:** ![antoniopaolini](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/antoniopaolini/32/12225_2.png) [@antoniopaolini](https://discourse.joplinapp.org/u/antoniopaolini)\
**Post date:** [22 February 2021 08:12 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/17 "2021-02-22T08:12:47Z")

</div>

It's really easy. You have to make a template.

1. Go to menu "File -\> Templates -\> Open template directory"
2. Make a file date.md with this content:  
`{{#customdatetime}}YYMMDD{{/customdatetime}}`
3. Go to menu "File -\> Template -\> refresh templates"
4. Use the shortcut "CTRL+ALT +i" ("COMMAND +OPTION + i" on Mac) and select the template.
5. Done

---

<div class="post-metadata">

**Author:** ![skim1124](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/skim1124/32/7296_2.png) [@skim1124](https://discourse.joplinapp.org/u/skim1124)\
**Post date:** [22 February 2021 08:44 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/18 "2021-02-22T08:44:26Z")

</div>

Thanks. I didn't realize it was so easy. But I think I had to edit it to be custom\_datetime before I got it to work. Also, I had a hard time saving an .md file (as opposed to .txt file); finally had to use Typora.

And as far as I understand, the use of templates is limited to date/time related items?

---

<div class="post-metadata">

**Author:** ![antoniopaolini](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/antoniopaolini/32/12225_2.png) [@antoniopaolini](https://discourse.joplinapp.org/u/antoniopaolini)\
**Post date:** [22 February 2021 10:03 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/19 "2021-02-22T10:03:46Z")

</div>

### Template:

You are wrong 😉, it is really easy. You can do what I said and it's works.  
This is the template you want.  
[data - Momentjs - YYMMDD.md](https://discourse.joplinapp.org/uploads/short-url/i0dsYSyWovQtxmqvkismyvJkMZq.md) (46 Bytes)

Moreover, for date/time you can use this sort of template, but you can do any template you want putting the text you want to insert in.  
For example I use template for fast inserting style tags in my notes, (see the attached file)[stile.md](https://discourse.joplinapp.org/uploads/short-url/7d98grfbmnpOwW17xARggH6Hrga.md) (90 Bytes)  
Others example here: [GitHub - WinkoErades/Joplin-note-taking-templates: Joplin note taking templates](https://github.com/WinkoErades/Joplin-note-taking-templates)

* * *

### moment.js:

What you need to know from moment.js is only the string format it accept. See tables under this paragraph: [Moment.js | Docs](https://momentjs.com/docs/#/parsing/string-format/)

* * *

### Edit .md files:

Last thing: edit md file does not require Typora (that also is a good markdown editor). A markdown file is a plain text file. You can edit it with notepad (or any plain text editor like VS Code, Vim, Notepad++, etc etc) and then save with the .md extension (if you save it ad .txt you can simply rename it and change the extension).

Hope this was useful.

---

<div class="post-metadata">

**Author:** ![skim1124](https://yyz2.discourse-cdn.com/flex028/user_avatar/discourse.joplinapp.org/skim1124/32/7296_2.png) [@skim1124](https://discourse.joplinapp.org/u/skim1124)\
**Post date:** [22 February 2021 10:19 UTC](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878/20 "2021-02-22T10:19:41Z")

</div>

I should have been more clear. In the original instructions you gave me, it was {{#customdatetime}}YYMMDD{{/customdatetime}}

But that didn't work for me until I put in an underscore between custom and datetime: {{#custom\_datetime}}YYMMDD{{/custom\_datetime}}

Anyway, I appreciate all your expert help because I like to use YYMMDD universally to identify the date.

[Next page](https://discourse.joplinapp.org/t/feature-request-insert-date-only-button/14878.md?page=2)
