This is what worked for my with my oldest, now 9 yrs old, when he went through that phase. I told him he could say f--- or s--- all he wanted, but he'd better not say crocodile...or SKUNK (while looking around as if to make sure no one hears me)!! Especially SKUNK because that is SUCH as bad word because skunks stink soooo bad and squirt their stink on people..ooooh we don't say skunk.
Then I walked away.
Later on we went shopping and he shouted SKUNK throughout the store...I gasped, appeared shocked (which is what they want you know!!) and he giggled and was generally pleased with himself. but he never really said f---- or s---- again and if he said any other "unsavory words" I'd go OH MY DID YOU SAY SKUNK?!?!?! shhhhhh! :)
Good luck!