I think you need to provide more info to help you.
1. Which distro?
2. Does the mail arrive correctly in dovecot ?
Squirrelmail does not recieve mail on it's own, it just connects to an imap server, as far as I remember.
So first thing to check would be, if you can connect with Thunderbird or any other imap client to the mailbox on the dovecot server .
If not, you have a dovecot problem, not a Squirrelmail problem
If yes, check your squirrelmail configuration, if it uses the right user and password, or check your apache error logs for for hints like open basedir stuff etc