Dock connector for sure. The home button plugs into the dock connector. That would explain why both the home button and the charging isn't working. I've replaced my dock connector on my iPhone 4 and it now works great.
Used this guide to replace a home button on my iPhone 4 which stopped working after the iPhone was out in the rain for 30 minutes. Worked like a charm. It was very hard but I took my time. Unfortunately, it didn't fix my problem. Upon further research, the dock connector was the culprit. It is where the home button plugs into. Replaced that using a guide here and now everything works great. So if your home button doesn't work after replacing the physical button, try replacing the dock connector.