[Tex/LaTex] How to redefine the \today with superscript

datedatetimeisodatesuperscriptsxetex

How can I redefine \today so that today's current date comes in the format

May 26th, 2016

I need the "th" to be superscript.

It should come to the bottom right corner of the page. The code does not work when I use it in the following environment XeLaTeX.

%  Preamble:
\NeedsTeXFormat{LaTeX2e}
\LoadClass{article}
\usepackage[head=12pt, foot=12pt, top=18mm, bottom=15mm, left=12.7mm, right=12.7mm]{geometry}
\usepackage[absolute]{textpos}
\usepackage[UKenglish]{babel}
\usepackage[en-US]{datetime2}
\DTMlangsetup{ord=raise}
\usepackage{rotating}

%  Main Tex:

\begin{document}
\setlength{\TPHorizModule}{1mm}
\setlength{\TPVertModule}{1mm}
\textblockorigin{0mm}{5mm} 
\begin{textblock}{60}(205,207)
\begin{turn}{90} 
Last Updated on
\today
\end{turn}
\end{textblock}
\end{document}

I need this to come as [Last Updated on May 26th, 2016]. "th / st /nd " raised to superscript height. Rotated 90 Deg. Bottom Right Corner of page. Please Check MWE Link Below.

Also I Keep getting this Warning:

Package datetime2 Warning: Region `english-base' has ignored (datetime2) the following settings: (datetime2) ord=raise on input line 13.

Link to MWE:
https://www.overleaf.com/5308800stsrzk#/16764374/

Best Answer

I suggest you use the datetime2 package with the option en-US:

enter image description here

The instruction \DTMlangsetup{ord=raise} instructs datetime2 to treat the day number as an ordinal and to raise the st/nd/rd particles to superscript height.

\documentclass{article}
\usepackage[en-US]{datetime2}
\DTMlangsetup{ord=raise}
\begin{document}
\today
\end{document}

Addendum to address the OP's augmented question: It looks like you're using UKenglish as the main language option for babel, yet also wanting a US-style date string ("May 26th, 2016" -- with "th" raised) rather than a UK-style date string ("26th May 2016" -- "th" not raised). To achieve this objective, you need to (a) provide "USenglish" as a secondary language option when loading babel and (b) execute the instruction \selectlanguage{USenglish} inside the textblock environment.

The code shown below should compile equally well under pdfLaTeX, XeLaTeX, and LuaLaTeX.

\documentclass{article}
\usepackage[head=12pt,foot=12pt,top=18mm,bottom=15mm,hmargin=12.7mm]{geometry}
\usepackage[absolute]{textpos}    
\usepackage[USenglish,UKenglish]{babel}   
\usepackage[en-US]{datetime2}
\DTMlangsetup[en-US]{ord=raise}    
\usepackage{rotating} % provides \turn macro

\begin{document}
\setlength{\TPHorizModule}{1mm}
\setlength{\TPVertModule}{1mm}
\textblockorigin{0mm}{5mm} 

\begin{textblock}{60}(205,207)
\selectlanguage{USenglish}
\begin{turn}{90} 
Last Updated on \today
\end{turn}
\end{textblock}

\end{document}