I have two boys so I know how it goes! We had to start taking them out every hour so they wouldn't mark. We have been pretty successful with this strategy! However, and not everyone agrees with this, but we crate them when we are gone, including when we are at work. We tried gates awhile back but they would escape. They go in willingly because they get a treat each time.
I also have my mother come over everyday for a long potty break so they're not in there more than a few hours at a time. Crate training has worked well for us - also we use it if they don't pee outside. They go in the crate for 20 min or so then back outside. Haven't had to do this in a long time though. Good luck!!