Hyperlink with port number not working

You should try doing this:

rails console
SiteSetting.port = 3000
exit