the pcms root:
/~mysite/myfolder/
should probably just be:
/myfolder/
assuming that you access it using:
myfolder/
the login issue could be a session management issue.
try testing the servers session management using the sessiontest.php page from the following post:
showpost.php?p=23826&postcount=2