Update prefCookie.js

Fixed a bug where the cookie would delete itself upon refresh if the form in the document was left empty.
Added a function checkTheBoxes() that reads any existing cookie and checks the checkboxes of all categories that were stored in it.