You can either paste the entire line ( <a href="javascript:window.close();">Close Page</a> ) onto your page (right-click and choose 'Paste HTML Placeholder')
Or create your own text first, swipe-select it and in the link properties use: javascript:window.close();
(* make sure you have deselected 'Correct automatically')