So I looked at Link to add to google calendar, but I want to do the same with an all day event.
I've tried doing dates={date.getUTCDate()}
, but the link doesn't take me to a google cal add event page (it just takes me to my calendar), I suspect because the date is wrong.
Thanks
If you don't put a time in the link it seems to mark the event as all day, for example: 20160627/20160627
So if you want a one day all day event for June 27 it would look like (using the example from "Link to add to google calendar"):
<a href="http://www.google.com/calendar/event?
action=TEMPLATE
&text=[event-title]
&dates=20160627/20160627
&details=[description]
&location=[location]
&trp=false
&sprop=
&sprop=name:"
target="_blank" rel="nofollow">Add to my calendar</a>
For a 2 day event it would look like (notice you have to add one extra day):
<a href="http://www.google.com/calendar/event?
action=TEMPLATE
&text=[event-title]
&dates=20160627/20160629
&details=[description]
&location=[location]
&trp=false
&sprop=
&sprop=name:"
target="_blank" rel="nofollow">Add to my calendar</a>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With