<a href="[[~21? &service=logout]]" title="Logout">Logout</a>
This question has been answered by BobRay. See the first response.
[[!Login? &redirectToPrior=`yes`]]
&logoutResourceId=`12`
Try adding this to the Login tag on the Login page:
&logoutResourceId=`12`
Change 12 to the ID of the Login page.
PS: please don't double post.