There's very little to do.
(1) To get the page to access via https, just use https:// instead of http:// as the scheme when typing the URL in the browser location bar or when writing links.
(2) To enforce that a particular script can only be accessed via https, test that it's being loaded that way by saying, e.g.:
if ($SERVER_PORT != '443')
{
header('Location: /');
exit;
}
NB port 443 is common for https, but just like the main http port can be configured to anything the site wants to use.