If my group is 3 players, we cancel if someone can't make it. If it's 4, we'll play with one person missing. Five or more, we'll play with two people missing, unless the game involves a major plot point, in which case we'll only play with one missing.
If I cancelled games whenever someone couldn't make it, we'd never play. There's simply too much real life going on, and we have scheduled game times every week.
As far as how to handle it, it's based entirely on circumstances. If there's a convenient way to work out the character, I'll do so. (Guarding the entrance, making a run into town, captured by ghouls and being slowly eaten alive, etc.) If not, the character may be run by someone else, if they're willing to run two for the evening. If not, the character is "semi-present." Officially, he's with the party. Unofficially, he doesn't do anything. Assume he's hanging back during negotiations, and assume every combat has either one extra opponent I didn't mention, or has a few "phantom hit points" I didn't mention, and the absent character is dealing with those while the present group handles the "real" fight.
Only rarely, if ever, will I NPC an absent character. I've got enough to do as the DM, thanks.
As far as XP, I don't give XP by the book anyway. I prefer to base advancement entirely on story awards, RP awards, and a general sense of how quickly I want the group to advance. So people who can't make it still get full XP, as long as there's an even vaguely legit reason for their absence. They do not, of course, have opportunity to earn extra XP through RP or problem-solving. The group I game with but do not run for, however, does XP by the book, so if you're not there, you don't get any.