concerning encryption, a good starting point is the doc page on mcrypt (www.php.net/mcrypt), the module which allows u to utilise a wide variety of ciphers. i suggest to use AES (aka RIJNDAEL, e.g. with 192 key bits). i.e., u could hash the user's password with md5 and then use this value to encrypt the data in your db. to simplify this, u can write functions that allow transparent access to encrypted db data, like this:
function getValue($user, $pw, $query)
{
// get the data from db
// loop through rs, decrypt using $pw
// return query result
}
u see, it's just pseudo code, but i hope this gives u an idea on how to start. in general, u should be very careful when writing some security system: even if they know your algorithm, hackers should still be unable to crack your code. read a few faqs (do a google search) to get the priciples of encryption, write your code, test it, test it again.
if u need any further help with more concrete problems, e.g. on mcrypt, feel free to ask.
concernin the write only machine... it will be very hard, even if u set the unix permissions appropriately, u will encounter problems coz mysql needs to read the dbs before writing (i think, at least). the maybe best way is to use the mysql permissions (even if they can be broken, since i think it is possible to limit a user's access to a certain ip address (range) - u need to look up this in the mysql docu, or ask in their forum.
hth