I don't think that you'll need a script for that unless you want to create duplicate layouts and direct web users to the duplicates--where you've made changes to the layout to make the fields read-only.
You can keep one set of layouts and set up password controlled access that allows web users in as guests and set up the guest privilege set to only allow read-only access to your data.
Is it possible to view the database as only a guest on other computers? I'm on the main computer now, where I can run FMS/Pro, and edit the database.
Is it possible to view the database locally on another computer, only as a guest?
Basically once my database goes online with a domain name/isn't local any more, I only want guests to be able to view the records, not be able to alter them.
There's a standard privlege set for "guest" access. You can use that or set up your own.