All soldiers in all armies were paid during the World Wars, with the sole exception being when prisoners were forced to fight by the people holding them. Conscripts were still supposed to be paid, as far as I've heard.
Now, that doesn't necessarily mean you'd see the money right away, or even at all. Some situations, like being stuck in Bastogne or serving in the Battle of Stalingrad, might limit your ability to receive your earnings for a while, and there are obviously going to be occasional glitches in the system where the payment office thinks you died or something. Plus, civilians fighting to defend their city when it is under siege obviously wouldn't be paid, and I doubt the Germans fighting to defend Berlin saw any money after the collapse of the Third Reich. But even they, in theory, were supposed to be paid.
In fact, I've read some stories about soldiers in certain areas being quite happy with how they were paid: the interviews accompanying the miniseries Band of Brothers, for example, mention that paratroopers were paid double (if I recall) the normal $50 salary of standard infantry soldiers, which motivated a lot of people to sign up for the more dangerous job.
As for how they were paid, that would probably vary from country to country, maybe even from branch to branch, and between the two wars. You'd need to research the specific situation you were interested in for more details.