There are a few interpretations that I have come across regarding the specific meaning of this verse, but all agree that this is a small argument in a wider context, not a change of direction from the verses before and after it:
John Stevenson (a Presbyterian theologian) argues that "for" in this case means "in the place of". This was a time when Chrisitans were heavily persecuted and frequently killed, yet the gospel message was spreading and more believers were being baptised. So Stevenson asserts that this verse is asking (rhetorically), "why, when so many Christians are being killed for their faith, are people still becoming Christians and being baptised, replacing those who were killed?"
Meanwhile, Matt Slick of the Christian Apologetics and Research Ministry concentrates on the meaning of the word "they" as opposed to "we". He asserts that Paul is talking not about Christians, but about a pagan religion from Eleusis, north of Corinth, who believed that baptising in the sea guaranteed a good afterlife. Slick's interpretation is that Paul is saying "if even the pagans believe in the resurrection and the importance of baptism, why can't you?"
The Restored Church of God teaches that the word "for" should be translated as "in the hope of" and asserts that the meaning is much more straightforward: if there is no bodily resurrection, we have no hope after we die. We therefore believe and are baptised because we do have hope that the dead will rise again.
While these interpretations vary in their conclusions regarding what Paul was specifically referring to, they all make the point that the verse must be taken in context. Stevenson explains,
The context of this passage is one in which Paul is arguing on behalf
of the doctrine of the bodily resurrection. The Greeks as a rule did
not hold to a bodily resurrection. It was a new concept to them. Their
religion taught that the afterlife consisted of a disembodied
existence. Throughout this chapter, Paul gives one argument after
another showing that Christians legitimately believe in a
So the verse itself doesn't result in specific doctrines in protestant churches outside of LDS, because the verse is part of a much wider set of arguments for the doctrines of baptism and the bodily resurrection.
I've picked on a few particular resources that address this issue but there are several others that also support the argument that the verse should be taken in the context described above and not as an indication of support for baptism on behalf of those that have already died. In addition, here's a specific rebuttal of the Mormon view from David Pratte's gospelway.com website.
Otherwise, what will those do who are baptized for the dead? If the
dead are not raised at all, why then are they baptized for them? Why
are we also in danger every hour? I affirm, brethren, by the boasting
in you which I have in Christ Jesus our Lord, I die daily. If from
human motives I fought with wild beasts at Ephesus, what does it
profit me? If the dead are not raised, let us eat and drink, for
tomorrow we die. Do not be deceived: 'Bad company corrupts good
morals.' Become sober-minded as you ought, and stop sinning; for some
have no knowledge of God. I speak this to your shame.
Paul's mention of this particular type of proxy baptism was in response to the question of the resurrection. If there is no resurrection of the dead, then why were people practicing a baptism for the dead?
The practice of a proxy baptism –
“What will those do who are baptized for the dead? Why then are they baptized for them?”
The first thing that has to be acknowledged here is that Paul affirms the existence of this practice.
The second thing is that the existence of this practice testifies to the importance the early Church placed on baptism, even though this practice represents a perversion of it.
The third thing is that Paul does not ask, “why do you or we” but, why do “they,” (whoever the ‘they' were). Paul is clearly separating himself and those at Corinth who did not practice this ritual for the dead, from those who did. It must also be noted that Paul is not giving credence to the practice. He simply acknowledges that some, whom he does not identify, were practicing this and it would appear that it was from among some of those who were claiming there was no resurrection. This reveals the existence of yet another faction that existed among those at Corinth just like this who were forbidding to marry. Just like those who had divided into factions over baptism, etc…, some were teaching that there was no resurrection from the dead while at the same time practicing this proxy ritual of baptism for the dead. Paul was not offering a defense for this practice. Rather, he was stressing the obvious absurdity of denying the resurrection and then baptizing for those who had died. How would they propose to defend the logic of this? Paul was not legitimizing the practice, he is showing the absurdity of it.
If there is no resurrection, then the patient endurance of persecution and constant dangers for the sake of the gospel was all for nothing.
“Why are we also in danger every hour?”
All of the profound experiences of suffering that Paul and others endured would have all been meaningless.
Why not just eat drink and be merry? If there is no resurrection, then life is of no more value than the satisfaction of one's appetites. If there is no resurrection then the satisfying of all fleshly appetites would be the highest and most noble aspiration we could hope to attain in this life. If there is no resurrection and we deny ourselves the greatest pleasures of this life, then all we are doing is robbing ourselves. Death, then, is the ultimate end of pleasures and we should enjoy every pleasure of life to its fullest because this is all there is. These are the consequences if there is no resurrection. On the other side of the coin, if there is a resurrection then the appetites of the flesh must be brought under control.
Disclaimer: This is from personal Bible study, therefore I quote only the Bible.
Some crucial points:
The context is about resurrection and not baptism - baptism is just mentioned in the passing - neither before this verse nor after this verse is the emphasis on baptism
“For as in Adam all die, even so in Christ shall all be made alive. But every man in his own order: Christ the firstfruits; afterward they that are Christ’s at his coming.” (1 Corinthians 15:22–23, KJV 1900)
Paul is trying to point out the reason why people get baptized for the dead - the answer being the point of the context - the hope of resurrection
Paul is stating a fact here - He says there were some people who were baptized for the sake of their dead ones (may I presume and say dead loved ones?) in the hope of resurrection.
Consider hypothetically a scenario where a non-christian husband is attending the funeral of christian wife. There, when all he hoped to see were a few crying church members, he sees something extremely weird - the church members, though sorrowful, are not in despair - why? Because they know their beloved sister will rise to never die again and they will eternally unite with her in the presence of their beloved Savior. She is sown and not buried, as far as the church members are concerned.
This impresses the husband (unbeliever) and because he loved his wife, he wants to know more about this "Resurrection" that all the church members are talking about and in the course of time, comes to believe in Christ and gets baptized in the hope of seeing his wife resurrected again.
Now the verse says
“Else what shall they do which are baptized for the dead, if the dead rise not at all? why are they then baptized for the dead?” (1 Corinthians 15:29, KJV 1900)
I think now the verse becomes self-explanatory. Events like the hypothetical one describe above should have been extremely common in the period of the Apostles as there was a huge inflow of believers into the church. Comparing with what Jesus said in the following quoted verse, it becomes clear:
“For I am come to set a man at variance against his father, and the daughter against her mother, and the daughter in law against her mother in law. And a man’s foes shall be they of his own household.” (Matthew 10:35–36, KJV 1900)
Paul then goes on to explain that he stands in jeopardy every hour because he believes in the resurrection - that Christ resurrected and therefore every man would resurrect in his own order (verse 22 and 23 quoted at the top)
In view of the fact that this sort of situation is an extremely common one known by all christians, Paul might have omitted the explanation of the immediate context. "Baptism for the dead" might have been a famous mode of church expansion in Corinth.
Baptism for the dead may have a more prosaic meaning if one takes into consideration that some in the early church practiced baptism upon conversion but once a year on Easter. If someone became a Christian but died before they would have been baptized on Easter, a friend or relative might complete the baptism ceremony for them as a memorial.